Skip to content

Commit

Permalink
Broadcast custom_json with active authority
Browse files Browse the repository at this point in the history
* custom_json with required_auths are now broadcasted with active key
* json field in custom_json is broadcasted compact (spaces are removed)
  • Loading branch information
holgern committed Mar 1, 2019
1 parent ba294ec commit 360f3e7
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
5 changes: 4 additions & 1 deletion beem/steem.py
Expand Up @@ -1604,7 +1604,10 @@ def custom_json(self,
"id": id,
"prefix": self.prefix,
})
return self.finalizeOp(op, account, "posting", **kwargs)
if len(required_auths) > 0:
return self.finalizeOp(op, account, "active", **kwargs)
else:
return self.finalizeOp(op, account, "posting", **kwargs)

def post(self,
title,
Expand Down
2 changes: 1 addition & 1 deletion beembase/operations.py
Expand Up @@ -394,7 +394,7 @@ def __init__(self, *args, **kwargs):
kwargs = args[0]
if "json" in kwargs and kwargs["json"]:
if (isinstance(kwargs["json"], dict) or isinstance(kwargs["json"], list)):
js = json.dumps(kwargs["json"])
js = json.dumps(kwargs["json"], separators=(',',':'))
else:
js = kwargs["json"]

Expand Down

0 comments on commit 360f3e7

Please sign in to comment.