Skip to content

Commit

Permalink
Small update WalletKey docstring
Browse files Browse the repository at this point in the history
  • Loading branch information
Cryp Toon committed May 16, 2024
1 parent 48e9b2f commit 7b3bf2a
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions bitcoinlib/wallets.py
Original file line number Diff line number Diff line change
Expand Up @@ -546,14 +546,15 @@ def key(self):
"""
Get HDKey object for current WalletKey
:return HDKey:
:return HDKey, list of HDKey:
"""

self._hdkey_object = None
if self.key_type == 'multisig':
self._hdkey_object = []
for kc in self._dbkey.multisig_children:
self._hdkey_object.append(HDKey.from_wif(kc.child_key.wif, network=kc.child_key.network_name, compressed=self.compressed))
self._hdkey_object.append(HDKey.from_wif(kc.child_key.wif, network=kc.child_key.network_name,
compressed=self.compressed))
if self._hdkey_object is None and self.wif:
self._hdkey_object = HDKey.from_wif(self.wif, network=self.network_name, compressed=self.compressed)
return self._hdkey_object
Expand Down

0 comments on commit 7b3bf2a

Please sign in to comment.