From 96b3e1ea74c2a28842c04891c8d6bd99e2fb3c86 Mon Sep 17 00:00:00 2001 From: Ri Xu Date: Thu, 16 Nov 2017 10:24:45 +0800 Subject: [PATCH] Bugfix: corrupted xlsx after write operation, relate issue #152. Signed-off-by: Ri Xu --- excelize.go | 2 +- xmlWorksheet.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/excelize.go b/excelize.go index 6b22385..b3abc30 100644 --- a/excelize.go +++ b/excelize.go @@ -135,7 +135,7 @@ func checkSheet(xlsx *xlsxWorksheet) { // Office Excel 2007. func replaceWorkSheetsRelationshipsNameSpace(workbookMarshal string) string { oldXmlns := `` - newXmlns := `` + newXmlns := `` workbookMarshal = strings.Replace(workbookMarshal, oldXmlns, newXmlns, -1) return workbookMarshal } diff --git a/xmlWorksheet.go b/xmlWorksheet.go index de7ea93..d0f4f5d 100644 --- a/xmlWorksheet.go +++ b/xmlWorksheet.go @@ -357,7 +357,7 @@ type xlsxSheetProtection struct { // properties specify how to display that phonetic run. type xlsxPhoneticPr struct { Alignment string `xml:"alignment,attr,omitempty"` - FontID int `xml:"fontId,attr,omitempty"` + FontID *int `xml:"fontId,attr"` Type string `xml:"type,attr,omitempty"` }