Skip to content
Snippets Groups Projects
Commit e444224a authored by crokkon's avatar crokkon
Browse files

adding account.get_creator()

parent 84ecec90
No related branches found
No related tags found
No related merge requests found
......@@ -324,6 +324,16 @@ class Account(BlockchainObject):
VoteValue = self.steem.sp_to_sbd(sp, voting_power=voting_power * 100, vote_pct=voting_weight * 100)
return VoteValue
def get_creator(self):
""" Returns the account creator or `None` if the account was mined
"""
if self['mined']:
return None
ops = list(self.get_account_history(0, 0))
if not ops or 'creator' not in ops[0]:
return None
return ops[0]['creator']
def get_recharge_time_str(self, voting_power_goal=100):
""" Returns the account recharge time
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment