Skip to content

Commit

Permalink
fix: remove unnecessary SetParams in upgrade handler (#299) (#302)
Browse files Browse the repository at this point in the history
* Update version and add fee param

* err handle

* add module to store upgrade struct

* edit tag

* remove setparams from upgrage handler

(cherry picked from commit f8640a0)

Co-authored-by: akrem <[email protected]>
  • Loading branch information
github-actions[bot] and akremstudy authored Aug 26, 2024
1 parent 41bf924 commit 9febaa5
Showing 1 changed file with 0 additions and 8 deletions.
8 changes: 0 additions & 8 deletions app/app.go
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,6 @@ import (
"cosmossdk.io/client/v2/autocli"
"cosmossdk.io/core/appmodule"
"cosmossdk.io/log"
"cosmossdk.io/math"
storetypes "cosmossdk.io/store/types"
"cosmossdk.io/x/evidence"
evidencekeeper "cosmossdk.io/x/evidence/keeper"
Expand Down Expand Up @@ -999,13 +998,6 @@ func (app *App) RegisterUpgradeHandlers() {
app.UpgradeKeeper.SetUpgradeHandler(
UpgradeName,
func(ctx context.Context, _ upgradetypes.Plan, fromVM module.VersionMap) (module.VersionMap, error) {
sdkctx := sdk.UnwrapSDKContext(ctx)
params := app.GlobalFeeKeeper.GetParams(sdkctx)
params.MinimumGasPrices = sdk.NewDecCoins(sdk.NewDecCoinFromDec(BondDenom, math.LegacyNewDecWithPrec(25, 4)))
err := app.GlobalFeeKeeper.SetParams(sdkctx, params)
if err != nil {
return nil, err
}
return app.ModuleManager().RunMigrations(ctx, app.Configurator(), fromVM)
},
)
Expand Down

0 comments on commit 9febaa5

Please sign in to comment.