Skip to content

Commit

Permalink
comment
Browse files Browse the repository at this point in the history
  • Loading branch information
samsondav committed Jun 28, 2024
1 parent 291e59e commit 27a24e2
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions llo/plugin.go
Original file line number Diff line number Diff line change
Expand Up @@ -768,6 +768,8 @@ func (p *Plugin) Outcome(outctx ocr3types.OutcomeContext, query types.Query, aos
for channelHash, dfnWithID := range updateChannelDefinitionsByHash {
orderedHashes = append(orderedHashes, hashWithID{channelHash, dfnWithID})
}
// Use predictable order for adding channels (id asc) so that extras that
// exceed the max are consistent across all nodes
sort.Slice(orderedHashes, func(i, j int) bool { return orderedHashes[i].ChannelID < orderedHashes[j].ChannelID })
for _, hwid := range orderedHashes {
voteCount := updateChannelVotesByHash[hwid.ChannelHash]
Expand Down

0 comments on commit 27a24e2

Please sign in to comment.