X-Git-Url: http://git.osdn.net/view?p=bytom%2Fpybtm.git;a=blobdiff_plain;f=pybtm%2Fkey.py;h=c34c2fad22bc252e31736adcc26fcb067cbd0c4d;hp=d1d977c475aa8d9aaa280604a49cda5505c1c980;hb=765c7da228fd54bc3f848eb9695499050a40949d;hpb=b0835da2e041955d0d93c5118dcacfa8c177ae27 diff --git a/pybtm/key.py b/pybtm/key.py index d1d977c..c34c2fa 100644 --- a/pybtm/key.py +++ b/pybtm/key.py @@ -365,9 +365,9 @@ def get_new_key(entropy_hexstr=None, mnemonic_str=None): if (entropy_hexstr is None) and (mnemonic_str is None): entropy_hexstr = get_entropy() mnemonic_str = get_mnemonic(entropy_hexstr) - if (entropy_hexstr is None) and (mnemonic_str is not None): + elif (entropy_hexstr is None) and (mnemonic_str is not None): entropy_hexstr = '' - if entropy_hexstr is not None: + elif entropy_hexstr is not None: mnemonic_str = get_mnemonic(entropy_hexstr) seed_hexstr = get_seed(mnemonic_str) root_xprv_hexstr = get_root_xprv(seed_hexstr)