mirror of
https://github.com/nspcc-dev/neo-go.git
synced 2024-11-23 13:38:35 +00:00
core: remove persisting from GetValidators()
It's a getter function and even though it's quite fancy with its transactions processing (for consensus operation) it shouldn't ever change the state of the Blockchain. If we're to change anything here these changes may conflict with the actual block processing later or may lead to broken state (if transactions won't be approved for some reason).
This commit is contained in:
parent
31dbc35279
commit
eb1749d190
1 changed files with 0 additions and 4 deletions
|
@ -1249,10 +1249,6 @@ func (bc *Blockchain) GetValidators(txes ...*transaction.Transaction) ([]*keys.P
|
|||
for i := 0; i < uniqueSBValidators.Len() && result.Len() < count; i++ {
|
||||
result = append(result, uniqueSBValidators[i])
|
||||
}
|
||||
_, err = cache.store.Persist()
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return result, nil
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue