summaryrefslogtreecommitdiff
path: root/file.go
diff options
context:
space:
mode:
Diffstat (limited to 'file.go')
-rw-r--r--file.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/file.go b/file.go
index 83ed271..6a48c0c 100644
--- a/file.go
+++ b/file.go
@@ -123,7 +123,7 @@ func (f *File) WriteToBuffer() (*bytes.Buffer, error) {
}
}
- if f.options != nil {
+ if f.options != nil && f.options.Password != "" {
if err := zw.Close(); err != nil {
return buf, err
}