Skip to content

Commit

Permalink
Fix pubsub slice counts in v7 upgrade
Browse files Browse the repository at this point in the history
  • Loading branch information
EricBolten committed Jan 28, 2024
1 parent 34bf424 commit 73ae885
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions app/upgrades/v7/upgrades.go
Original file line number Diff line number Diff line change
Expand Up @@ -249,7 +249,7 @@ func pubsubInitGenesis(ctx sdk.Context, pubsubKeeper pubsubkeeper.Keeper) {
}

// Set 7seas publisher intents for existing cellars
publisherIntents := make([]*pubsubtypes.PublisherIntent, 0, 25)
publisherIntents := make([]*pubsubtypes.PublisherIntent, 0, 28)
for _, cellar := range cellars {
publisherIntents = append(publisherIntents, &pubsubtypes.PublisherIntent{
SubscriptionId: cellar,
Expand All @@ -260,7 +260,7 @@ func pubsubInitGenesis(ctx sdk.Context, pubsubKeeper pubsubkeeper.Keeper) {
}

// Set default subscriptions for 7seas as the publisher for existing cellars
defaultSubscriptions := make([]*pubsubtypes.DefaultSubscription, 0, 25)
defaultSubscriptions := make([]*pubsubtypes.DefaultSubscription, 0, 28)
for _, cellar := range cellars {
defaultSubscriptions = append(defaultSubscriptions, &pubsubtypes.DefaultSubscription{
SubscriptionId: cellar,
Expand All @@ -270,7 +270,7 @@ func pubsubInitGenesis(ctx sdk.Context, pubsubKeeper pubsubkeeper.Keeper) {

// Create subscribers and intents for existing validators
subscribers := createSubscribers()
subscriberIntents := make([]*pubsubtypes.SubscriberIntent, 0, 875)
subscriberIntents := make([]*pubsubtypes.SubscriberIntent, 0, 980)
for _, subscriber := range subscribers {
for _, cellar := range cellars {
subscriberIntents = append(subscriberIntents, &pubsubtypes.SubscriberIntent{
Expand Down

0 comments on commit 73ae885

Please sign in to comment.