don't decode bytes to unicode twice

Signed-off-by: Doug Hellmann <doug@doughellmann.com>
This commit is contained in:
Doug Hellmann 2017-10-03 13:02:48 -04:00
parent abebd9894a
commit 3077d6dca4
1 changed files with 1 additions and 2 deletions

View File

@ -95,8 +95,7 @@ def main():
sys.stderr.write('Could not get hash for ref %r\n' % ref)
return 1
ref_hash_str = ref_hash.decode('utf8')
url = '%s/%s/%s/' % (args.base, ref_hash_str[:2], ref_hash_str)
url = '%s/%s/%s/' % (args.base, ref_hash[:2], ref_hash)
if args.url:
print(url)