Skip to content

Commit

Permalink
CNS upgrade plan 0.5.0 (#284)
Browse files Browse the repository at this point in the history
* rename to 0.5.0

* lint fix

* lint fix

---------

Co-authored-by: Yarom Swisa <[email protected] git config --global user.name Yarom>
  • Loading branch information
Yaroms and Yarom Swisa authored Feb 2, 2023
1 parent f0b35aa commit 636ce15
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 7 deletions.
4 changes: 2 additions & 2 deletions app/app.go
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ import (
"github.com/ignite-hq/cli/ignite/pkg/openapiconsole"
"github.com/lavanet/lava/app/keepers"
"github.com/lavanet/lava/app/upgrades"
"github.com/lavanet/lava/app/upgrades/v0_4_6"
"github.com/lavanet/lava/app/upgrades/v0_5_0"
"github.com/lavanet/lava/docs"
conflictmodule "github.com/lavanet/lava/x/conflict"
conflictmodulekeeper "github.com/lavanet/lava/x/conflict/keeper"
Expand Down Expand Up @@ -116,7 +116,7 @@ const (
)

// Upgrades add here future upgrades (upgrades.Upgrade)
var Upgrades = []upgrades.Upgrade{upgrades.Upgrade_0_4_0, upgrades.Upgrade_0_4_3, upgrades.Upgrade_0_4_4, upgrades.Upgrade_0_4_5, v0_4_6.Upgrade_v0_4_6}
var Upgrades = []upgrades.Upgrade{upgrades.Upgrade_0_4_0, upgrades.Upgrade_0_4_3, upgrades.Upgrade_0_4_4, upgrades.Upgrade_0_4_5, v0_5_0.Upgrade}

// this line is used by starport scaffolding # stargate/wasm/app/enabledProposals

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package v0_4_6
package v0_5_0

import (
"log"
Expand All @@ -13,9 +13,9 @@ import (
spectypes "github.com/lavanet/lava/x/spec/types"
)

const UpgradeName = "v0.4.6"
const UpgradeName = "v0.5.0"

var Upgrade_v0_4_6 = upgrades.Upgrade{
var Upgrade = upgrades.Upgrade{
UpgradeName: UpgradeName, // upgrade name defined few lines above
CreateUpgradeHandler: CreateUpgradeHandler, // create CreateUpgradeHandler in upgrades.go below
StoreUpgrades: store.StoreUpgrades{}, // StoreUpgrades has 3 fields: Added/Renamed/Deleted any module that fits these description should be added in the way below
Expand Down
4 changes: 2 additions & 2 deletions x/epochstorage/keeper/stake_storage.go
Original file line number Diff line number Diff line change
Expand Up @@ -230,7 +230,7 @@ func (k Keeper) RemoveStakeEntryCurrent(ctx sdk.Context, storageType string, cha
func (k Keeper) AppendStakeEntryCurrent(ctx sdk.Context, storageType string, chainID string, stakeEntry types.StakeEntry) {
// this stake storage entries are sorted by stake amount
stakeStorage, found := k.GetStakeStorageCurrent(ctx, storageType, chainID)
entries := []types.StakeEntry{}
var entries []types.StakeEntry
if !found {
entries = []types.StakeEntry{stakeEntry}
// create a new one
Expand Down Expand Up @@ -354,7 +354,7 @@ func (k Keeper) AppendUnstakeEntry(ctx sdk.Context, storageType string, stakeEnt

// this stake storage entries are sorted by deadline
stakeStorage, found := k.GetStakeStorageUnstake(ctx, storageType)
entries := []types.StakeEntry{}
var entries []types.StakeEntry
if !found {
entries = []types.StakeEntry{stakeEntry}
// create a new one
Expand Down

0 comments on commit 636ce15

Please sign in to comment.