Skip to content

Commit 24484cc

Browse files
committed
fix "AttributeError: 'str' object has no attribute 'decode'" Exception
fix kevinxucs#7 (comment)
1 parent 1e2043f commit 24484cc

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

gitignore.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -40,13 +40,13 @@ def _loadfile(self, bp):
4040
package = zipfile.ZipFile(package_path, 'r')
4141
path = self._bp_folder + '/' + bp
4242
f = package.open(path, 'r')
43-
text = f.read().decode()
43+
text = f.read()
4444
f.close()
4545
return text
4646
else:
4747
file_path = os.path.join(package_path, self._bp_folder, bp)
4848
f = open(file_path, 'r')
49-
text = f.read().decode()
49+
text = f.read()
5050
f.close()
5151
return text
5252

0 commit comments

Comments
 (0)