Commit 2ca7c190 authored by Raymond Hettinger's avatar Raymond Hettinger

Remove dependency on order of mode flags

parent 46d96238
......@@ -193,7 +193,7 @@ class ZipFile:
self.NameToInfo = {} # Find file info given name
self.filelist = [] # List of ZipInfo instances for archive
self.compression = compression # Method of compression
self.mode = key = mode[0].replace('b', '')
self.mode = key = mode.replace('b', '')[0]
# Check if we were passed a file-like object
if isinstance(file, basestring):
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment