Skip to content

Commit 94c6c57

Browse files
committed
fix: set https scheme in case it is missing during node migration
1 parent db5fc69 commit 94c6c57

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

x/node/migrations/migrator.go

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ package migrations
33
import (
44
"net"
55
"net/url"
6+
"strings"
67
"time"
78

89
"github.com/cosmos/cosmos-sdk/codec"
@@ -88,6 +89,10 @@ func (k *Migrator) migrateNodes(ctx sdk.Context) {
8889
panic(err)
8990
}
9091

92+
if !strings.Contains(item.RemoteURL, "://") {
93+
item.RemoteURL = "https://" + item.RemoteURL
94+
}
95+
9196
remoteURL, err := url.ParseRequestURI(item.RemoteURL)
9297
if err != nil {
9398
panic(err)

0 commit comments

Comments
 (0)