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'); 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); }