Skip to content

Commit 80a490c

Browse files
committed
naming
1 parent 45d74c7 commit 80a490c

File tree

4 files changed

+12
-12
lines changed

4 files changed

+12
-12
lines changed

x/ccv/consumer/keeper/migration.go

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -21,16 +21,16 @@ func NewMigrator(ccvConsumerKeeper Keeper, ccvConsumerParamSpace paramtypes.Subs
2121
return Migrator{ccvConsumerKeeper: ccvConsumerKeeper, ccvConsumerParamSpace: ccvConsumerParamSpace}
2222
}
2323

24-
func (m Migrator) Migratev1p0To1p3(ctx sdk.Context) error {
24+
func (m Migrator) Migratev1Tov2(ctx sdk.Context) error {
2525
// Migrate params
26-
MigrateParamsv1p0To1p3(ctx, m.ccvConsumerParamSpace)
26+
MigrateParamsv1Tov2(ctx, m.ccvConsumerParamSpace)
2727

2828
return nil
2929
}
3030

31-
// MigrateParamsv1p0To1p3 migrates the consumer CCV module params from v1.0.0 to v1.3.0,
31+
// MigrateParamsv1Tov2 migrates the consumer CCV module params from v1.0.0 to v2.0.0,
3232
// setting default values for new params.
33-
func MigrateParamsv1p0To1p3(ctx sdk.Context, paramsSubspace paramtypes.Subspace) {
33+
func MigrateParamsv1Tov2(ctx sdk.Context, paramsSubspace paramtypes.Subspace) {
3434
// Get old params
3535
var enabled bool
3636
paramsSubspace.Get(ctx, v1consumertypes.KeyEnabled, &enabled)

x/ccv/consumer/keeper/migration_test.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ import (
2020
tmdb "github.com/tendermint/tm-db"
2121
)
2222

23-
func TestMigrateParamsv1p0To1p3(t *testing.T) {
23+
func TestMigrateParamsv1Tov2(t *testing.T) {
2424
// Setup raw store
2525
db := tmdb.NewMemDB()
2626
stateStore := store.NewCommitMultiStore(db)
@@ -76,7 +76,7 @@ func TestMigrateParamsv1p0To1p3(t *testing.T) {
7676
).WithKeyTable(v2consumertypes.ParamKeyTable()) // Use v2 key table, this would be set in keeper constructor upon app init
7777

7878
// Run migration
79-
v2consumerkeeper.MigrateParamsv1p0To1p3(ctx, subspace)
79+
v2consumerkeeper.MigrateParamsv1Tov2(ctx, subspace)
8080

8181
// Use v2 keeper to confirm params are set correctly
8282
keeper := v2consumerkeeper.Keeper{}

x/ccv/provider/keeper/migration.go

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -25,9 +25,9 @@ func NewMigrator(ccvProviderKeeper Keeper, stakingKeeper v2ccvtypes.StakingKeepe
2525
return Migrator{ccvProviderKeeper: ccvProviderKeeper, ccvProviderParamSpace: ccvProviderParamSpace}
2626
}
2727

28-
func (m Migrator) Migratev1p0To1p3(ctx sdk.Context) error {
28+
func (m Migrator) Migratev1Tov2(ctx sdk.Context) error {
2929
// Migrate params
30-
MigrateParamsv1p0To1p3(ctx,
30+
MigrateParamsv1Tov2(ctx,
3131
m.ccvProviderParamSpace,
3232
// See https://github.com/cosmos/interchain-security/blob/7861804cb311507ec6aebebbfad60ea42eb8ed4b/x/ccv/provider/keeper/params.go#L84
3333
// The v1.1.0-multiden version of ICS hardcodes this param as 10 of bond type: k.stakingKeeper.BondDenom(ctx).
@@ -38,9 +38,9 @@ func (m Migrator) Migratev1p0To1p3(ctx sdk.Context) error {
3838
return nil
3939
}
4040

41-
// MigrateParamsv1p0To1p3 migrates the provider CCV module params from v1.0.0 to v1.3.0,
41+
// MigrateParamsv1Tov2 migrates the provider CCV module params from v1.0.0 to v2.0.0,
4242
// setting default values for new params.
43-
func MigrateParamsv1p0To1p3(ctx sdk.Context, paramsSubspace paramtypes.Subspace, consumerRewardDenomRegistrationFee sdk.Coin) {
43+
func MigrateParamsv1Tov2(ctx sdk.Context, paramsSubspace paramtypes.Subspace, consumerRewardDenomRegistrationFee sdk.Coin) {
4444
// Get old params
4545
var templateClient ibctmtypes.ClientState
4646
paramsSubspace.Get(ctx, v1providertypes.KeyTemplateClient, &templateClient)

x/ccv/provider/keeper/migration_test.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ import (
2020
tmdb "github.com/tendermint/tm-db"
2121
)
2222

23-
func TestMigrateParamsv1p0To1p3(t *testing.T) {
23+
func TestMigrateParamsv1Tov2(t *testing.T) {
2424
// Setup raw store
2525
db := tmdb.NewMemDB()
2626
stateStore := store.NewCommitMultiStore(db)
@@ -69,7 +69,7 @@ func TestMigrateParamsv1p0To1p3(t *testing.T) {
6969
).WithKeyTable(v2providertypes.ParamKeyTable()) // Use v2 key table, this would be set in keeper constructor upon app init
7070

7171
// Run migration
72-
v2providerkeeper.MigrateParamsv1p0To1p3(ctx, subspace, sdk.NewCoin("uatom", sdk.NewInt(100000)))
72+
v2providerkeeper.MigrateParamsv1Tov2(ctx, subspace, sdk.NewCoin("uatom", sdk.NewInt(100000)))
7373

7474
// Use keeper to confirm params are set correctly
7575
keeper := v2providerkeeper.Keeper{}

0 commit comments

Comments
 (0)