setAttribute should be setTextAttribute for a group separator symbol.

This commit is contained in:
Steve Ireland
2023-06-04 08:47:12 -04:00
parent 9ee0bb1ed4
commit 97dfdf2f78

View File

@@ -384,7 +384,7 @@ function to_decimals(?float $number, string $decimals = NULL, int $type = Number
if(empty($config['thousands_separator']))
{
$fmt->setAttribute(NumberFormatter::GROUPING_SEPARATOR_SYMBOL, '');
$fmt->setTextAttribute(NumberFormatter::GROUPING_SEPARATOR_SYMBOL, '');
}
$fmt->setSymbol(NumberFormatter::CURRENCY_SYMBOL, $config['currency_symbol']);