Skip to content
Snippets Groups Projects
Unverified Commit bd8cf746 authored by Holger Nahrstaedt's avatar Holger Nahrstaedt Committed by GitHub
Browse files

Merge pull request #14 from crokkon/account_history_reverse_block_date

account.history_reverse() fix for TypeError
parents baab5e57 f44af1a0
Branches
Tags
No related merge requests found
......@@ -1331,13 +1331,13 @@ class Account(BlockchainObject):
est_diff = 0
if isinstance(start, (datetime, date, time)):
for h in self.get_account_history(op_est, 0):
block_date = h["timestamp"]
block_date = formatTimeString(h["timestamp"])
while(op_est + est_diff + batch_size < first and block_date < start):
est_diff += batch_size
if op_est + est_diff > first:
est_diff = first - op_est
for h in self.get_account_history(op_est + est_diff, 0):
block_date = h["timestamp"]
block_date = formatTimeString(h["timestamp"])
else:
for h in self.get_account_history(op_est, 0):
block_num = h["block"]
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment