Merge pull request #141 from WingGao/wing

fix OpenReader no sheet error
formula
xuri 7 years ago committed by GitHub
commit a4ffb4fbfc
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -39,8 +39,6 @@ func OpenFile(filename string) (*File, error) {
return nil, err
}
f.Path = filename
f.sheetMap = f.getSheetMap()
f.Styles = f.stylesReader()
return f, nil
}
@ -60,12 +58,15 @@ func OpenReader(r io.Reader) (*File, error) {
if err != nil {
return nil, err
}
return &File{
f := &File{
checked: make(map[string]bool),
Sheet: make(map[string]*xlsxWorksheet),
SheetCount: sheetCount,
XLSX: file,
}, nil
}
f.sheetMap = f.getSheetMap()
f.Styles = f.stylesReader()
return f, nil
}
// setDefaultTimeStyle provides function to set default numbers format for

Loading…
Cancel
Save