Skip to content

Commit

Permalink
fix: missing s3 await
Browse files Browse the repository at this point in the history
  • Loading branch information
BobTheBuidler committed Oct 12, 2023
1 parent 8dc2bd3 commit 031be91
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions yearn/apy/staking_rewards.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,11 @@ async def get_staking_rewards_apr(vault, samples: ApySamples):
return 0

vault_address = str(vault.vault)
if vault_address not in vault.registry.staking_pools:
staking_pools = await vault.registry.staking_pools
if vault_address not in staking_pools:
return 0

staking_pool = await Contract.coroutine(vault.registry.staking_pools[vault_address])
staking_pool = await Contract.coroutine(staking_pools[vault_address])
if await staking_pool.periodFinish.coroutine() < now:
return 0

Expand Down

0 comments on commit 031be91

Please sign in to comment.