fix Path.read
This commit is contained in:
parent
65a513916b
commit
5b81b1a339
|
@ -120,8 +120,8 @@ class Path(str):
|
|||
|
||||
|
||||
def read(self, byte=False):
|
||||
fd = open(self)
|
||||
data = fd.read('rb' if byte else 'r')
|
||||
fd = open(self, 'rb' if byte else 'r')
|
||||
data = fd.read()
|
||||
fd.close()
|
||||
|
||||
return data
|
||||
|
|
Loading…
Reference in a new issue