diff --git a/src/classes/sanitiser.php b/src/classes/sanitiser.php index 2e088c1e..b53b62b3 100644 --- a/src/classes/sanitiser.php +++ b/src/classes/sanitiser.php @@ -6,7 +6,7 @@ class Sanitiser { public static function getNumber(mixed $valueToSanitise): float { - return preg_replace('/[^0-9\.]+/', '', $valueToSanitise); + return floatval(preg_replace('/[^0-9\.]+/', '', $valueToSanitise)); } public static function getPage(mixed $valueToSanitise): string