From 30e6b044cf292b2630967156bd5f9bb1f987dcb9 Mon Sep 17 00:00:00 2001 From: thomasv Date: Thu, 19 Jan 2012 17:25:25 +0100 Subject: [PATCH] move urldecode to the executable file --- client/electrum | 6 ++++++ client/wallet.py | 3 --- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/client/electrum b/client/electrum index 67a9f4c5..26c2d269 100755 --- a/client/electrum +++ b/client/electrum @@ -23,6 +23,12 @@ from optparse import OptionParser from wallet import Wallet from interface import Interface + +# URL decode +_ud = re.compile('%([0-9a-hA-H]{2})', re.MULTILINE) +urldecode = lambda x: _ud.sub(lambda m: chr(int(m.group(1), 16)), x) + + if __name__ == '__main__': known_commands = ['help', 'validateaddress', 'balance', 'contacts', 'create', 'payto', 'sendtx', 'password', 'newaddress', 'addresses', 'history', 'label', 'gui', 'mktx','seed','import'] diff --git a/client/wallet.py b/client/wallet.py index 52ec655a..9d3773ad 100644 --- a/client/wallet.py +++ b/client/wallet.py @@ -151,9 +151,6 @@ def int_to_hex(i, length=1): return s.decode('hex')[::-1].encode('hex') -# URL decode -_ud = re.compile('%([0-9a-hA-H]{2})', re.MULTILINE) -urldecode = lambda x: _ud.sub(lambda m: chr(int(m.group(1), 16)), x) # AES EncodeAES = lambda secret, s: base64.b64encode(aes.encryptData(secret,s))