Skip to content

Commit

Permalink
fix: delete async task if block is not found (#1299)
Browse files Browse the repository at this point in the history
  • Loading branch information
jyeshe committed May 4, 2023
1 parent 693b936 commit 6b4d3d7
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion lib/ae_mdw/sync/async_tasks/store_account_balance.ex
Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,11 @@ defmodule AeMdw.Sync.AsyncTasks.StoreAccountBalance do
accounts_tree <- :aec_trees.accounts(trees),
balances <- get_balances(accounts_tree, account_set) do
update_balances(balances)
done_fn.()
end
end)

done_fn.()

if time_delta / @milisecs > @log_threshold_ms do
Log.info("[store_account_balance] #{inspect(block_index)} after #{time_delta / @milisecs}s")
end
Expand Down

0 comments on commit 6b4d3d7

Please sign in to comment.