From b39025573afd9a53b08285f0a0bcf564fd44dae0 Mon Sep 17 00:00:00 2001
From: Philip Offtermatt
Date: Wed, 12 Jun 2024 09:17:28 +0200
Subject: [PATCH] Add comment for migration
---
x/ccv/provider/migrations/migrator.go | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/x/ccv/provider/migrations/migrator.go b/x/ccv/provider/migrations/migrator.go
index 6d384c5d2e..abc23c42d0 100644
--- a/x/ccv/provider/migrations/migrator.go
+++ b/x/ccv/provider/migrations/migrator.go
@@ -42,13 +42,15 @@ func (m Migrator) Migrate3to4(ctx sdktypes.Context) error {
return nil
}
-// MigrateXtoY migrates x/ccvprovider state from consensus version 4 to 5.
+// Migrate4to5 migrates x/ccvprovider state from consensus version 4 to 5.
// The migration consists of setting a top N of 95 for all registered consumer chains.
func (m Migrator) Migrate4to5(ctx sdktypes.Context) error {
v5.MigrateTopNForRegisteredChains(ctx, m.providerKeeper)
return nil
}
+// Migrate5to6 migrates x/ccvprovider state from consensus version 5 to 6.
+// The migration consists of computing and storing the minimal power in the top N for all registered consumer chains.
func (m Migrator) Migrate5to6(ctx sdktypes.Context) error {
v6.MigrateMinPowerInTopN(ctx, m.providerKeeper)
return nil