Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fixing inflation api #467

Merged
merged 1 commit into from
Jul 24, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion x/jklmint/keeper/keeper.go
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,13 @@

var blocksPerYearEstiamte int64 = (365 * 24 * 60 * 60) / 6

printedPerYear := blocksPerYearEstiamte * 1_000_000 * params.TokensPerBlock
mintedNum := params.TokensPerBlock
minted, found := k.GetMintedBlock(ctx, ctx.BlockHeight()-1)
if found {
mintedNum = minted.Minted

Check warning on line 103 in x/jklmint/keeper/keeper.go

View check run for this annotation

Codecov / codecov/patch

x/jklmint/keeper/keeper.go#L100-L103

Added lines #L100 - L103 were not covered by tests
}

printedPerYear := blocksPerYearEstiamte * mintedNum

Check warning on line 106 in x/jklmint/keeper/keeper.go

View check run for this annotation

Codecov / codecov/patch

x/jklmint/keeper/keeper.go#L106

Added line #L106 was not covered by tests

inflate := sdk.NewDec(printedPerYear)

Expand Down
Loading