Fix decodeAddress without bech32 hrp

This commit is contained in:
tecnovert
2022-11-14 13:54:48 +02:00
parent 54e434e1c9
commit 8ec6d55963
3 changed files with 9 additions and 3 deletions

View File

@@ -7,6 +7,7 @@
from .btc import BTCInterface
from basicswap.chainparams import Coins
from basicswap.util.address import decodeAddress
from mnemonic import Mnemonic
@@ -22,6 +23,9 @@ class DASHInterface(BTCInterface):
words = self.seedToMnemonic(key)
self.rpc_callback('upgradetohd', [words, ])
def decodeAddress(self, address):
return decodeAddress(address)[1:]
def checkExpectedSeed(self, key_hash):
try:
rv = self.rpc_callback('dumphdinfo')