1
0

base_encode/base_decode: change to saner API

This commit is contained in:
SomberNight
2019-12-08 06:19:51 +01:00
parent 01f94fcf58
commit 8cf3587aeb
4 changed files with 10 additions and 10 deletions

View File

@@ -846,7 +846,7 @@ def parse_URI(uri: str, on_pr: Callable = None, *, loop=None) -> dict:
raise InvalidBitcoinURI(f"failed to parse 'exp' field: {repr(e)}") from e
if 'sig' in out:
try:
out['sig'] = bh2u(bitcoin.base_decode(out['sig'], None, base=58))
out['sig'] = bh2u(bitcoin.base_decode(out['sig'], base=58))
except Exception as e:
raise InvalidBitcoinURI(f"failed to parse 'sig' field: {repr(e)}") from e