[#209] *: use current block index in `GetDesignatedByRole`

Signed-off-by: Evgenii Stratonikov <evgeniy@nspcc.ru>
remotes/1719329119662467860/v0.14.1-hotfix
Evgenii Stratonikov 2022-01-11 11:25:10 +03:00 committed by Alex Vanin
parent b8d2569f4d
commit ce391b108d
2 changed files with 2 additions and 2 deletions

View File

@ -124,7 +124,7 @@ func _deploy(data interface{}, isUpdate bool) {
// only by side chain committee.
func Update(script []byte, manifest []byte, data interface{}) {
blockHeight := ledger.CurrentIndex()
alphabetKeys := roles.GetDesignatedByRole(roles.NeoFSAlphabet, uint32(blockHeight))
alphabetKeys := roles.GetDesignatedByRole(roles.NeoFSAlphabet, uint32(blockHeight+1))
alphabetCommittee := common.Multiaddress(alphabetKeys, true)
common.CheckAlphabetWitness(alphabetCommittee)

View File

@ -52,7 +52,7 @@ func _deploy(data interface{}, isUpdate bool) {
// only by side chain committee.
func Update(script []byte, manifest []byte, data interface{}) {
blockHeight := ledger.CurrentIndex()
alphabetKeys := roles.GetDesignatedByRole(roles.NeoFSAlphabet, uint32(blockHeight))
alphabetKeys := roles.GetDesignatedByRole(roles.NeoFSAlphabet, uint32(blockHeight+1))
alphabetCommittee := common.Multiaddress(alphabetKeys, true)
if !runtime.CheckWitness(alphabetCommittee) {