Skip to content

Commit

Permalink
feat(mint): make param value consistent among example and tests
Browse files Browse the repository at this point in the history
  • Loading branch information
ezreal1997 committed Oct 9, 2024
1 parent f2dedc9 commit 2db0e58
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 7 deletions.
10 changes: 5 additions & 5 deletions client/x/mint/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -62,11 +62,11 @@ type InflationCalculationFn func(ctx sdk.Context, minter Minter, params Params,

The minting module contains the following parameters:

| Key | Type | Example |
|---------------------|-----------------|------------------------------|
| MintDenom | string | "stake" |
| InflationsPerYear | string (dec) | "24625000000000000" |
| BlocksPerYear | string (uint64) | "6311520" |
| Key | Type | Example |
|---------------------|-----------------|----------------------------------------|
| MintDenom | string | "stake" |
| InflationsPerYear | string (dec) | "24625000000000000.000000000000000000" |
| BlocksPerYear | string (uint64) | "6311520" |


## Events
Expand Down
2 changes: 1 addition & 1 deletion client/x/mint/keeper/genesis_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ func (s *GenesisTestSuite) TestImportExportGenesis() {
genesisState := types.DefaultGenesisState()
genesisState.Params = types.NewParams(
"testDenom",
math.LegacyNewDec(24625000000000000),
math.LegacyNewDec(24625000000000000.000000000000000000),
uint64(60*60*8766/5),
)

Expand Down
2 changes: 1 addition & 1 deletion client/x/mint/types/params.go
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ func NewParams(mintDenom string, inflationsPerYear math.LegacyDec, blocksPerYear
func DefaultParams() Params {
return Params{
MintDenom: sdk.DefaultBondDenom,
InflationsPerYear: math.LegacyNewDec(24625000_000_000_000),
InflationsPerYear: math.LegacyNewDec(24625000000000000.000000000000000000),
BlocksPerYear: uint64(60 * 60 * 8766 / 5), // assuming 5 second block times
}
}
Expand Down

0 comments on commit 2db0e58

Please sign in to comment.