Skip to content

Commit

Permalink
Merge pull request #9957 from vegaprotocol/fix_ds_order
Browse files Browse the repository at this point in the history
fix: first apply migration, then register the dispatch strategy
  • Loading branch information
jeremyletang committed Nov 2, 2023
1 parent a0af69d commit dec3c0e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion core/banking/checkpoint.go
Original file line number Diff line number Diff line change
Expand Up @@ -231,11 +231,11 @@ func (e *Engine) loadRecurringTransfers(
e.recurringTransfersMap[transfer.ID] = transfer
// reload the dispatch strategy to the hash cache
if transfer.DispatchStrategy != nil {
e.registerDispatchStrategy(transfer.DispatchStrategy)
// reset defaults for new dispatch strategy params:
if transfer.DispatchStrategy.EntityScope == vega.EntityScope_ENTITY_SCOPE_UNSPECIFIED {
e.applyMigrationDefaults(transfer.DispatchStrategy)
}
e.registerDispatchStrategy(transfer.DispatchStrategy)
}
evts = append(evts, events.NewRecurringTransferFundsEvent(ctx, transfer))
}
Expand Down

0 comments on commit dec3c0e

Please sign in to comment.