Merge pull request #1738 Fix inflation calculation period check

x/stake: Fix inflation calculation period check
This commit is contained in:
Rigel
2018-07-18 14:15:40 -04:00
committed by GitHub
2 changed files with 2 additions and 1 deletions
+1
View File
@@ -3,6 +3,7 @@
## PENDING
BREAKING CHANGES
* [x/stake] Fixed the period check for the inflation calculation
FEATURES
* [lcd] Can now query governance proposals by ProposalStatus
+1 -1
View File
@@ -39,7 +39,7 @@ func EndBlocker(ctx sdk.Context, k keeper.Keeper) (ValidatorUpdates []abci.Valid
// Process types.Validator Provisions
blockTime := ctx.BlockHeader().Time
if pool.InflationLastTime+blockTime >= 3600 {
if blockTime-pool.InflationLastTime >= 3600 {
pool.InflationLastTime = blockTime
pool = pool.ProcessProvisions(params)
}