commands: fix signtransaction cmd

fixes #6502
This commit is contained in:
SomberNight 2020-08-26 19:48:35 +02:00
parent b7c2820951
commit 54d2fa0e7d
No known key found for this signature in database
GPG key ID: B33B5F232C6271E9

View file

@ -394,7 +394,7 @@ class Commands:
@command('wp')
async def signtransaction(self, tx, privkey=None, password=None, wallet: Abstract_Wallet = None):
"""Sign a transaction. The wallet keys will be used unless a private key is provided."""
tx = PartialTransaction(tx)
tx = tx_from_any(tx)
if privkey:
txin_type, privkey2, compressed = bitcoin.deserialize_privkey(privkey)
pubkey = ecc.ECPrivkey(privkey2).get_public_key_bytes(compressed=compressed).hex()