summaryrefslogtreecommitdiff
path: root/excelize.go
diff options
context:
space:
mode:
authorxuri <xuri.me@gmail.com>2022-09-08 22:20:21 +0800
committerxuri <xuri.me@gmail.com>2022-09-08 22:20:21 +0800
commitfb1aab7add52808c96c9cc10570fe73ce797b7f4 (patch)
tree778202a8944ecad3c7f74edf4f9ac4b0a150f79d /excelize.go
parent0c5cdfec1868f31f6e355cdcb0a91220bad80522 (diff)
This closes #744, the `Save`, `Write` and `WriteTo` function accept saving options
Diffstat (limited to 'excelize.go')
-rw-r--r--excelize.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/excelize.go b/excelize.go
index f1269fe..bb4bde0 100644
--- a/excelize.go
+++ b/excelize.go
@@ -136,13 +136,13 @@ func newFile() *File {
// OpenReader read data stream from io.Reader and return a populated
// spreadsheet file.
-func OpenReader(r io.Reader, opt ...Options) (*File, error) {
+func OpenReader(r io.Reader, opts ...Options) (*File, error) {
b, err := ioutil.ReadAll(r)
if err != nil {
return nil, err
}
f := newFile()
- f.options = parseOptions(opt...)
+ f.options = parseOptions(opts...)
if f.options.UnzipSizeLimit == 0 {
f.options.UnzipSizeLimit = UnzipSizeLimit
if f.options.UnzipXMLSizeLimit > f.options.UnzipSizeLimit {