Skip to content

Commit

Permalink
add rate limit change
Browse files Browse the repository at this point in the history
  • Loading branch information
shellvish committed Oct 14, 2023
1 parent 2a0f911 commit 7b4eb66
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
1 change: 1 addition & 0 deletions app/upgrades.go
Original file line number Diff line number Diff line change
Expand Up @@ -212,6 +212,7 @@ func (app *StrideApp) setupUpgradeHandlers(appOpts servertypes.AppOptions) {
app.mm,
app.configurator,
app.StakeibcKeeper,
app.RatelimitKeeper,
),
)

Expand Down
6 changes: 6 additions & 0 deletions app/upgrades/v16/upgrades.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ import (
"github.com/cosmos/cosmos-sdk/types/module"
upgradetypes "github.com/cosmos/cosmos-sdk/x/upgrade/types"

ratelimitkeeper "github.com/Stride-Labs/stride/v15/x/ratelimit/keeper"
stakeibckeeper "github.com/Stride-Labs/stride/v15/x/stakeibc/keeper"
)

Expand All @@ -19,6 +20,7 @@ func CreateUpgradeHandler(
mm *module.Manager,
configurator module.Configurator,
stakeibcKeeper stakeibckeeper.Keeper,
ratelimitKeeper ratelimitkeeper.Keeper,
) upgradetypes.UpgradeHandler {
return func(ctx sdk.Context, _ upgradetypes.Plan, vm module.VersionMap) (module.VersionMap, error) {
ctx.Logger().Info("Starting upgrade v15...")
Expand All @@ -33,6 +35,10 @@ func CreateUpgradeHandler(
stakeibcKeeper.SetHostZone(ctx, hostZone)
}

// remove stuatom from rate limits
ctx.Logger().Info("Removing stuatom as a blacklisted asset...")
ratelimitKeeper.RemoveDenomFromBlacklist(ctx, "stuatom")

return mm.RunMigrations(ctx, configurator, vm)
}
}

0 comments on commit 7b4eb66

Please sign in to comment.