3
0
mirror of https://github.com/snipe/snipe-it.git synced 2026-02-05 12:55:46 +00:00

Fixed #10306 - cast purchase cost to a float

Signed-off-by: snipe <snipe@snipe.net>
This commit is contained in:
snipe
2025-08-11 18:12:37 +01:00
parent c8a5065ffa
commit f12a3bb08b

View File

@ -123,9 +123,9 @@ class Helper
if (is_numeric($cost)) {
if (Setting::getSettings()->digit_separator=='1.234,56') {
return number_format($cost, 2, ',', '.');
return (float) number_format($cost, 2, ',', '.');
}
return number_format($cost, 2, '.', ',');
return (float) number_format($cost, 2, '.', ',');
}
// It's already been parsed.
return $cost;