Skip to content
Prev Previous commit
Next Next commit
Fixed issue with python2. Issue with instance check for unicode
  • Loading branch information
Jwink3101 committed Sep 12, 2019
commit 89cc532b6e5e75b79ccd38d77e227d082c9fd44d
4 changes: 2 additions & 2 deletions git-fat
Original file line number Diff line number Diff line change
Expand Up @@ -208,7 +208,7 @@ class GitFat(object):
digest, bytes = self.decode_stream(open(fname))
except IOError:
return False, None
if isinstance(digest, str):
if isinstance(digest, (str,unicode)):
return digest, bytes
else:
return None, bytes
Expand Down Expand Up @@ -269,7 +269,7 @@ class GitFat(object):
def cmd_filter_smudge(self):
self.setup()
result, bytes = self.decode_stream(sys.stdin)
if isinstance(result, str): # We got a digest
if isinstance(result, (str,unicode)): # We got a digest
objfile = os.path.join(self.objdir, result)
try:
cat(open(objfile), sys.stdout)
Expand Down