20
0

Update col.go

check to nil
This commit is contained in:
KabylzhanA 2020-07-20 01:06:54 +06:00
parent 4a6cf26307
commit 24de6e2ecc

2
col.go
View File

@ -168,7 +168,7 @@ type NumberCol struct {
} }
func (c *NumberCol) String(wb *WorkBook) []string { func (c *NumberCol) String(wb *WorkBook) []string {
if fNo := wb.Xfs[c.Index].formatNo(); fNo != 0 { if fNo := wb.Xfs[c.Index].formatNo(); fNo != 0 && wb.Formats[fNo] != nil {
t := timeFromExcelTime(c.Float, wb.dateMode == 1) t := timeFromExcelTime(c.Float, wb.dateMode == 1)
return []string{yymmdd.Format(t, wb.Formats[fNo].str)} return []string{yymmdd.Format(t, wb.Formats[fNo].str)}
} }