mirror of
https://github.com/yiisoft/yii2.git
synced 2025-08-14 14:28:27 +08:00
Fixes #15015: Added StringHelper::floatToString()
to savely cast float values independent of the locale, also fixes some places in the framework that use it now
This commit is contained in:

committed by
Alexander Makarov

parent
f259eadf7a
commit
93bbf5b39d
@ -478,7 +478,7 @@ class BaseArrayHelper
|
||||
$value = static::getValue($element, $key);
|
||||
if ($value !== null) {
|
||||
if (is_float($value)) {
|
||||
$value = (string) $value;
|
||||
$value = StringHelper::floatToString($value);
|
||||
}
|
||||
$lastArray[$value] = $element;
|
||||
}
|
||||
|
Reference in New Issue
Block a user