Skip to content

Commit

Permalink
Implicit conversion from float to int Warning (#192)
Browse files Browse the repository at this point in the history
Fixes WARNING - Implicit conversion from float 89.99998842592592 to int loses precision in (...)/spatie/ssl-certificate/src/SslCertificate.php on line 165
  • Loading branch information
cord authored Sep 20, 2024
1 parent 57c2e63 commit e164c15
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/SslCertificate.php
Original file line number Diff line number Diff line change
Expand Up @@ -162,7 +162,7 @@ public function expirationDate(): Carbon

public function lifespanInDays(): int
{
return $this->validFromDate()->diffInDays($this->expirationDate(), false);
return (int)$this->validFromDate()->diffInDays($this->expirationDate(), false);
}

public function isExpired(): bool
Expand Down

0 comments on commit e164c15

Please sign in to comment.