update decode_address import from lbryschema

https://github.com/lbryio/lbryschema/pull/16
This commit is contained in:
Jack Robison 2017-09-06 10:58:52 -04:00
parent 1487ed713e
commit dd036d15c8
No known key found for this signature in database
GPG key ID: 284699E7404E3CFF

View file

@ -19,7 +19,7 @@ from lbryschema.claim import ClaimDict
from lbryschema.uri import parse_lbry_uri
from lbryschema.error import URIParseError
from lbryschema.validator import validate_claim_id
from lbryschema.base import base_decode
from lbryschema.address import decode_address
# TODO: importing this when internet is disabled raises a socket.gaierror
from lbrynet.core.system_info import get_lbrynet_version
@ -2312,8 +2312,8 @@ class Daemon(AuthJSONRPCServer):
raise NullFundsError()
if address:
if not base_decode(address, 58):
raise Exception("Given an invalid address to send to")
# raises an error if the address is invalid
decode_address(address)
result = yield self.jsonrpc_send_amount_to_address(amount, address)
else:
validate_claim_id(claim_id)