Skip to content

Commit f8668f4

Browse files
committed
Update register.py
1 parent cdcd34e commit f8668f4

File tree

1 file changed

+3
-5
lines changed

1 file changed

+3
-5
lines changed

src/lto/transactions/register.py

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -55,11 +55,9 @@ def to_binary(self):
5555

5656
@staticmethod
5757
def __account_to_json(account):
58-
try:
59-
if account['key_type']:
60-
return {'keyType': account['key_type'], 'publicKey': account['public_key']}
61-
except:
62-
return account
58+
if 'key_type' in account:
59+
return {'keyType': account['key_type'], 'publicKey': account['public_key']}
60+
return account
6361

6462
def to_json(self):
6563
return (crypto.merge_dicts({

0 commit comments

Comments
 (0)