From 8c35cca6093e9da8aff72add18e75d4979b29bc6 Mon Sep 17 00:00:00 2001 From: martianwei Date: Fri, 26 Jan 2024 06:59:04 +0000 Subject: [PATCH] fix: addNumfmt --- xmlStyle.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) 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()