Merge 33deb10aa769e9a98653c5bb79640c04c58882d9 into 5a7c2c1262ed683067c4ee074da104af658eddc7
This commit is contained in:
commit
dbaa57abf5
@ -213,6 +213,10 @@ class StyleHelper
|
||||
|
||||
$customNumberFormat = $customNumberFormats[$numFmtId];
|
||||
|
||||
if ($customNumberFormat === 'General') {
|
||||
return false;
|
||||
}
|
||||
|
||||
// Remove extra formatting (what's between [ ], the brackets should not be preceded by a "\")
|
||||
$pattern = '((?<!\\\)\[.+?(?<!\\\)\])';
|
||||
$customNumberFormat = preg_replace($pattern, '', $customNumberFormat);
|
||||
|
@ -121,6 +121,7 @@ class StyleHelperTest extends \PHPUnit_Framework_TestCase
|
||||
['m/d/yyyy;@', true],
|
||||
['[$-409]m/d/yy\--h:mm;@', true],
|
||||
['GENERAL', false],
|
||||
['General', false],
|
||||
['\ma\yb\e', false],
|
||||
['[Red]foo;', false],
|
||||
];
|
||||
|
Loading…
x
Reference in New Issue
Block a user