Skip to content

Commit

Permalink
review comments
Browse files Browse the repository at this point in the history
  • Loading branch information
arijitAD committed Nov 1, 2021
1 parent d1c874b commit fae0c34
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 2 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@ Ref: https://keepachangelog.com/en/1.0.0/

### API Breaking Changes

* (x/mint) [\#10441](https://github.com/cosmos/cosmos-sdk/pull/10441) The `NewAppModule` function now accepts an inflation calculation function as an argument.
* [\#10295](https://github.com/cosmos/cosmos-sdk/pull/10295) Remove store type aliases from /types
* [\#9695](https://github.com/cosmos/cosmos-sdk/pull/9695) Migrate keys from `Info` -> `Record`
* Add new `codec.Codec` argument in:
Expand Down
3 changes: 2 additions & 1 deletion x/mint/module.go
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,8 @@ type AppModule struct {
inflationCalculator types.InflationCalculationFn
}

// NewAppModule creates a new AppModule object
// NewAppModule creates a new AppModule object. If the InflationCalculationFn
// argument is nil, then the SDK's default inflation function will be used.
func NewAppModule(cdc codec.Codec, keeper keeper.Keeper, ak types.AccountKeeper, ic types.InflationCalculationFn) AppModule {
if ic == nil {
ic = types.DefaultInflationCalculationFn
Expand Down
2 changes: 1 addition & 1 deletion x/mint/types/genesis.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import (
type InflationCalculationFn func(ctx sdk.Context, minter Minter, params Params, bondedRatio sdk.Dec) sdk.Dec

// DefaultInflationCalculationFn is the default function used to calculate inflation.
func DefaultInflationCalculationFn(ctx sdk.Context, minter Minter, params Params, bondedRatio sdk.Dec) sdk.Dec {
func DefaultInflationCalculationFn(_ sdk.Context, minter Minter, params Params, bondedRatio sdk.Dec) sdk.Dec {
return minter.NextInflationRate(params, bondedRatio)
}

Expand Down

0 comments on commit fae0c34

Please sign in to comment.