Skip to content

Commit

Permalink
constant
Browse files Browse the repository at this point in the history
  • Loading branch information
Yarom Swisa authored and Yarom Swisa committed Jan 29, 2024
1 parent 082ddb7 commit fcbc822
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion x/rewards/keeper/providers.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@ import (
"github.com/lavanet/lava/x/rewards/types"
)

const DAY_SECONDS = 60 * 60 * 24

func (k Keeper) AggregateRewards(ctx sdk.Context, provider, chainid string, adjustment sdk.Dec, rewards math.Int) {
index := types.BasePayIndex{Provider: provider, ChainID: chainid}
basepay, found := k.getBasePay(ctx, index)
Expand Down Expand Up @@ -249,5 +251,5 @@ func (k Keeper) FundCommunityPoolFromModule(ctx sdk.Context, amount math.Int, se

// isEndOfMonth checks that we're close to next timer expiry by at least 24 hours
func (k Keeper) isEndOfMonth(ctx sdk.Context) bool {
return ctx.BlockTime().UTC().Unix()+86400 > k.TimeToNextTimerExpiry(ctx)
return ctx.BlockTime().UTC().Unix()+DAY_SECONDS > k.TimeToNextTimerExpiry(ctx)
}

0 comments on commit fcbc822

Please sign in to comment.