core: put candidate account to the storage during (*NEO).vote
C# node uses Snapshot.GetAndChange to get it from storage, so it's the same problem as with voting account. Affects dumps.
This commit is contained in:
parent
c63528db44
commit
b7194ec608
1 changed files with 5 additions and 0 deletions
|
@ -738,6 +738,11 @@ func (n *NEO) VoteInternal(ic *interop.Context, h util.Uint160, pub *keys.Public
|
|||
return errors.New("unknown validator")
|
||||
}
|
||||
cd := new(candidate).FromBytes(valSi)
|
||||
// we should put it in storage anyway as it affects dumps
|
||||
err = ic.DAO.PutStorageItem(n.ID, valKey, valSi)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if !cd.Registered {
|
||||
return errors.New("validator must be registered")
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue