tcheck parameter type of create_new_address - electrum - Electrum Bitcoin wallet (HTM) git clone https://git.parazyd.org/electrum (DIR) Log (DIR) Files (DIR) Refs (DIR) Submodules --- (DIR) commit 57baed4728174441d010766f792462ee6abf1aaa (DIR) parent db13cf965ccecee7c3bc851ce5d2c861e509efd0 (HTM) Author: ThomasV <thomasv@electrum.org> Date: Tue, 4 Apr 2017 13:52:16 +0200 check parameter type of create_new_address Diffstat: M lib/wallet.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) --- (DIR) diff --git a/lib/wallet.py b/lib/wallet.py t@@ -1466,7 +1466,8 @@ class Deterministic_Wallet(Abstract_Wallet): if n > nmax: nmax = n return nmax + 1 - def create_new_address(self, for_change): + def create_new_address(self, for_change=False): + assert type(for_change) is bool addr_list = self.change_addresses if for_change else self.receiving_addresses n = len(addr_list) x = self.derive_pubkeys(for_change, n)