Skip to content

Commit

Permalink
dummy upgrade for testing
Browse files Browse the repository at this point in the history
  • Loading branch information
AaronKutch committed Sep 17, 2023
1 parent 2a6d1f2 commit c8d0069
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 2 deletions.
4 changes: 2 additions & 2 deletions app/consumer-democracy/app.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import (
"os"
"path/filepath"

// v0 "github.com/onomyprotocol/multiverse/app/consumer-democracy/upgrades/"
v0_1_1_199_onex_dummy "github.com/onomyprotocol/multiverse/app/consumer-democracy/upgrades/v0.1.1.199-onex-dummy"

"github.com/cosmos/cosmos-sdk/baseapp"
"github.com/cosmos/cosmos-sdk/client"
Expand Down Expand Up @@ -909,7 +909,7 @@ func initParamsKeeper(appCodec codec.BinaryCodec, legacyAmino *codec.LegacyAmino
}

func (app *App) setupUpgradeHandlers() {
// app.UpgradeKeeper.SetUpgradeHandler(v0.Name, v0.UpgradeHandler)
app.UpgradeKeeper.SetUpgradeHandler(v0_1_1_199_onex_dummy.Name, v0_1_1_199_onex_dummy.UpgradeHandler)

upgradeInfo, err := app.UpgradeKeeper.ReadUpgradeInfoFromDisk()
if err != nil {
Expand Down
15 changes: 15 additions & 0 deletions app/consumer-democracy/upgrades/v0.1.1.199-onex-dummy/upgrade.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
package v0_1_1_199_onex_dummy //nolint:revive,stylecheck // app version

import (
sdk "github.com/cosmos/cosmos-sdk/types"
"github.com/cosmos/cosmos-sdk/types/module"
upgradetypes "github.com/cosmos/cosmos-sdk/x/upgrade/types"
)

// Name is migration name.
const Name = "v0.1.1.199-onex-dummy"

// UpgradeHandler is an x/upgrade handler.
func UpgradeHandler(_ sdk.Context, _ upgradetypes.Plan, vm module.VersionMap) (module.VersionMap, error) {
return vm, nil
}

0 comments on commit c8d0069

Please sign in to comment.