BUG: address json initialized with array of 1 dict, instead of dict

This commit is contained in:
Victor Grau Serrat
2018-02-05 22:17:21 -07:00
parent 3bc54a6c2e
commit 2168fb0d5b
+2 -1
View File
@@ -133,7 +133,8 @@ def get_user_pubaddr(environ=None):
return [data, ]
return data
else:
data = dict(pubAddr='', desc='')
data = []
data.append(dict(pubAddr='', desc=''))
with open(filename, 'w') as f:
json.dump(data, f, sort_keys=False, indent=2,
separators=(',', ':'))