consensus: don't do useless key sorting

They're already sorted out of smartcontract.CreateMultiSigRedeemScript().

Signed-off-by: Roman Khimov <roman@nspcc.ru>
This commit is contained in:
Roman Khimov 2024-08-26 19:23:58 +03:00
parent 32e3310205
commit e0cf47e6d0

View file

@ -4,7 +4,6 @@ import (
"errors" "errors"
"fmt" "fmt"
"slices" "slices"
"sort"
"sync/atomic" "sync/atomic"
"time" "time"
@ -652,8 +651,6 @@ func (s *service) getBlockWitness(b *coreb.Block) *transaction.Witness {
return nil return nil
} }
sort.Sort(keys.PublicKeys(pubs))
buf := io.NewBufBinWriter() buf := io.NewBufBinWriter()
for i, j := 0, 0; i < len(pubs) && j < m; i++ { for i, j := 0, 0; i < len(pubs) && j < m; i++ {
if sig, ok := sigs[pubs[i]]; ok { if sig, ok := sigs[pubs[i]]; ok {