summaryrefslogtreecommitdiff
path: root/comment.go
diff options
context:
space:
mode:
authorLunny Xiao <xiaolunwen@gmail.com>2018-05-07 16:12:51 +0800
committerLunny Xiao <xiaolunwen@gmail.com>2018-05-07 16:12:51 +0800
commit38ad20efc11c1872c4e62a12617f0300c138b867 (patch)
tree7190083ed4fa8ddaa1ec3b9ecb260423451f3164 /comment.go
parentbc451a78de32ccde2a4f6d0851ea6e41e45408f1 (diff)
save bytes on memory instead of string
Diffstat (limited to 'comment.go')
-rw-r--r--comment.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/comment.go b/comment.go
index 6f2d624..41b4d6b 100644
--- a/comment.go
+++ b/comment.go
@@ -142,7 +142,7 @@ func (f *File) addDrawingVML(commentID int, drawingVML, cell string) {
}
vml.Shape = append(vml.Shape, shape)
v, _ := xml.Marshal(vml)
- f.XLSX[drawingVML] = string(v)
+ f.XLSX[drawingVML] = v
}
// addComment provides function to create chart as xl/comments%d.xml by given
@@ -202,7 +202,7 @@ func (f *File) addComment(commentsXML, cell string, formatSet *formatComment) {
}
comments.CommentList.Comment = append(comments.CommentList.Comment, cmt)
v, _ := xml.Marshal(comments)
- f.saveFileList(commentsXML, string(v))
+ f.saveFileList(commentsXML, v)
}
// countComments provides function to get comments files count storage in the