mirror of
https://github.com/0glabs/0g-chain.git
synced 2024-12-26 00:05:18 +00:00
fix: check correct time elpased condition (#853)
This commit is contained in:
parent
0e718d3510
commit
26e88c6177
@ -662,7 +662,7 @@ func (k Keeper) ZeroHardLiquidityProviderClaim(ctx sdk.Context, claim types.Hard
|
||||
func CalculateTimeElapsed(start, end, blockTime time.Time, previousAccrualTime time.Time) sdk.Int {
|
||||
if (end.Before(blockTime) &&
|
||||
(end.Before(previousAccrualTime) || end.Equal(previousAccrualTime))) ||
|
||||
(start.After(previousAccrualTime)) ||
|
||||
(start.After(blockTime)) ||
|
||||
(start.Equal(blockTime)) {
|
||||
return sdk.ZeroInt()
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user