Skip to content

Commit

Permalink
fix: 🐛 init incentive module params (#76)
Browse files Browse the repository at this point in the history
  • Loading branch information
cosmic-vagabond authored May 11, 2023
1 parent 2c8ee4c commit c1e4af3
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
2 changes: 1 addition & 1 deletion app/app.go
Original file line number Diff line number Diff line change
Expand Up @@ -663,7 +663,7 @@ func NewElysApp(
// insert epoch hooks receivers here
app.OracleKeeper.Hooks(),
app.CommitmentKeeper.Hooks(),
// app.IncentiveKeeper.Hooks(),
app.IncentiveKeeper.Hooks(),
app.BurnerKeeper.Hooks(),
),
)
Expand Down
5 changes: 4 additions & 1 deletion app/setup_handlers.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,9 @@ func setUpgradeHandler(app *ElysApp) {
app.UpgradeKeeper.SetUpgradeHandler(version.Version, func(ctx sdk.Context, plan types.Plan, vm m.VersionMap) (m.VersionMap, error) {
app.Logger().Info("Running upgrade handler for " + version.Version)

// init genesis for new incentive module
app.IncentiveKeeper.InitGenesis(ctx, *incentivemoduletypes.DefaultGenesis())

return app.mm.RunMigrations(ctx, app.configurator, vm)
})
}
Expand All @@ -31,7 +34,7 @@ func loadUpgradeStore(app *ElysApp) {

if shouldLoadUpgradeStore(app, upgradeInfo) {
storeUpgrades := storetypes.StoreUpgrades{
Added: []string{incentivemoduletypes.StoreKey},
// Added: []string{},
}
// Use upgrade store loader for the initial loading of all stores when app starts,
// it checks if version == upgradeHeight and applies store upgrades before loading the stores,
Expand Down

0 comments on commit c1e4af3

Please sign in to comment.