diff --git a/xmlStyle.go b/xmlStyle.go index 2d58a58e..5636b285 100644 --- a/xmlStyle.go +++ b/xmlStyle.go @@ -501,7 +501,7 @@ func (styles *xlsxStyleSheet) newNumFmt(formatCode string) xlsxNumFmt { // addNumFmt add xlsxNumFmt if its not exist. func (styles *xlsxStyleSheet) addNumFmt(xNumFmt xlsxNumFmt) { // don't add built in NumFmt - if xNumFmt.NumFmtId <= builtinNumFmtsCount { + if _, ok := builtInNumFmt[xNumFmt.NumFmtId]; ok { return } styles.numFmtRefTableMU.RLock()