Skip to content

Commit

Permalink
chore(redelegations): use constant value for redelegations period
Browse files Browse the repository at this point in the history
  • Loading branch information
dtfiedler committed Nov 16, 2024
1 parent a343fcd commit da407d2
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/gar.lua
Original file line number Diff line number Diff line change
Expand Up @@ -1827,7 +1827,7 @@ function gar.redelegateStake(params)
sourceGateway = sourceGateway,
targetGateway = targetGateway,
redelegationFee = redelegationFee,
feeResetTimestamp = currentTimestamp + 7 * 24 * 60 * 60 * 1000, -- 7 days
feeResetTimestamp = currentTimestamp + constants.redelegationFeeResetIntervalMs,
redelegationsSinceFeeReset = Redelegations[delegateAddress].redelegations,
}
end
Expand All @@ -1843,7 +1843,9 @@ function gar.getRedelegationFee(delegateAddress)

return {
redelegationFeePct = redelegationFeePct,
feeResetTimestamp = previousRedelegations and previousRedelegations.timestamp + 7 * 24 * 60 * 60 * 1000 or nil,
feeResetTimestamp = previousRedelegations
and previousRedelegations.timestamp + constants.redelegationFeeResetIntervalMs
or nil,
}
end

Expand Down

0 comments on commit da407d2

Please sign in to comment.