URI: 
       tfix bug with has_seed - electrum - Electrum Bitcoin wallet
  HTML git clone https://git.parazyd.org/electrum
   DIR Log
   DIR Files
   DIR Refs
   DIR Submodules
       ---
   DIR commit 84052bcdb2bac78f424d2478014c37cd752e217d
   DIR parent dc22ba4d5ea6036bca3768aaf01e88bd3d049069
  HTML Author: ThomasV <thomasv@gitorious>
       Date:   Wed, 30 Apr 2014 15:44:46 +0200
       
       fix bug with has_seed
       
       Diffstat:
         M lib/bitcoin.py                      |       6 +++++-
         M lib/wallet.py                       |       4 ++--
       
       2 files changed, 7 insertions(+), 3 deletions(-)
       ---
   DIR diff --git a/lib/bitcoin.py b/lib/bitcoin.py
       t@@ -299,7 +299,11 @@ def is_address(addr):
        
        
        def is_private_key(key):
       -    return ASecretToSecret(key) is not False
       +    try:
       +        k = ASecretToSecret(key) 
       +        return k is not False
       +    except:
       +        return False
        
        
        ########### end pywallet functions #######################
   DIR diff --git a/lib/wallet.py b/lib/wallet.py
       t@@ -1126,10 +1126,10 @@ class Deterministic_Wallet(Abstract_Wallet):
                Abstract_Wallet.__init__(self, storage)
        
            def has_seed(self):
       -        return self.seed == ''
       +        return self.seed != ''
        
            def is_watching_only(self):
       -        return self.has_seed()
       +        return not self.has_seed()
        
            def check_password(self, password):
                self.get_seed(password)