URI: 
       tfollow up previous commit - electrum - Electrum Bitcoin wallet
  HTML git clone https://git.parazyd.org/electrum
   DIR Log
   DIR Files
   DIR Refs
   DIR Submodules
       ---
   DIR commit 23f36ea080b747463030d928adcc787c84918a08
   DIR parent 6e9b2a4459a108d438a917241c97f315544644c9
  HTML Author: ThomasV <thomasv@electrum.org>
       Date:   Sat, 16 Sep 2017 11:00:20 +0200
       
       follow up previous commit
       
       Diffstat:
         M lib/bitcoin.py                      |       6 +++---
       
       1 file changed, 3 insertions(+), 3 deletions(-)
       ---
   DIR diff --git a/lib/bitcoin.py b/lib/bitcoin.py
       t@@ -335,8 +335,8 @@ def script_to_p2wsh(script):
        
        
        def address_to_script(addr):
       -    if is_segwit_address(addr):
       -        witver, witprog = segwit_addr.decode(SEGWIT_HRP, addr)
       +    witver, witprog = segwit_addr.decode(SEGWIT_HRP, addr)
       +    if witprog is not None:
                assert (0 <= witver <= 16)
                OP_n = witver + 0x50 if witver > 0 else 0
                script = bytes([OP_n]).hex()
       t@@ -506,7 +506,7 @@ def address_from_private_key(sec):
        
        def is_segwit_address(addr):
            witver, witprog = segwit_addr.decode(SEGWIT_HRP, addr)
       -    return witver == 0
       +    return witprog is not None and witver == 0
        
        def is_b58_address(addr):
            try: