From 18776846ed559c91dd3230fa715de4a43cd35dff Mon Sep 17 00:00:00 2001 From: LucaMortillaro Date: Wed, 27 May 2026 19:09:38 +0200 Subject: [PATCH 1/2] :wrench: roman_year() explicit nullable param (PHP 8.5 deprecation) --- src/datetime.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/datetime.php b/src/datetime.php index c5d2b5c..9617c79 100644 --- a/src/datetime.php +++ b/src/datetime.php @@ -209,7 +209,7 @@ function carbon(string $date, string $format = DATE_TIME_FORMAT_ISO): Carbon\Car * @return string * @see https://github.com/spatie-custom/blender/blob/master/app/Foundation/helpers.php */ -function roman_year(int $year = null): string +function roman_year(?int $year = null): string { if (!is_numeric($year)) { $year = (int)date('Y'); From 79af1b63cb702f1d83a5e9b551d5fdbd13cfb797 Mon Sep 17 00:00:00 2001 From: LucaMortillaro Date: Wed, 27 May 2026 19:11:24 +0200 Subject: [PATCH 2/2] :wrench: replace (double) cast with (float) (PHP 8.5 deprecation) --- src/validation.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/validation.php b/src/validation.php index b29188f..3758ac4 100644 --- a/src/validation.php +++ b/src/validation.php @@ -127,7 +127,7 @@ function isIntegerFloatingPoint($value, $unsigned = true): bool && $value <= PHP_INT_MAX && $value >= PHP_INT_MIN //big number rouned to int aproximately! //big number change into exp format - && ((int)((double)$value) == $value || (int)$value == $value || strpos(strtoupper((string)$value), + && ((int)((float)$value) == $value || (int)$value == $value || strpos(strtoupper((string)$value), 'E') === false); }