git://git.novaco.in
/
electrum-nvc.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
(parent:
fa4c2b9
)
fix: num_accounts should return only confirmed bip32 accounts
author
ThomasV
<thomasv@gitorious>
Mon, 5 May 2014 10:17:25 +0000 (12:17 +0200)
committer
ThomasV
<thomasv@gitorious>
Mon, 5 May 2014 10:17:25 +0000 (12:17 +0200)
lib/account.py
patch
|
blob
|
history
lib/wallet.py
patch
|
blob
|
history
diff --git
a/lib/account.py
b/lib/account.py
index
c4cfa6a
..
66e6b73
100644
(file)
--- a/
lib/account.py
+++ b/
lib/account.py
@@
-71,7
+71,7
@@
class PendingAccount(Account):
def dump(self):
return {'pending':self.addresses[0]}
- def get_name(self):
+ def get_name(self, k):
return _('Pending account')
diff --git
a/lib/wallet.py
b/lib/wallet.py
index
557b8e2
..
ebd2429
100644
(file)
--- a/
lib/wallet.py
+++ b/
lib/wallet.py
@@
-1391,7
+1391,12
@@
class NewWallet(Deterministic_Wallet):
def num_accounts(self):
- keys = self.accounts.keys()
+ keys = []
+ for k, v in self.accounts.items():
+ if type(v) != BIP32_Account:
+ continue
+ keys.append(k)
+
i = 0
while True:
account_id = self.account_id(i)