From b989fdb462c89ef997f51ead9fce9b08f02d1f6d Mon Sep 17 00:00:00 2001 From: Anna Shaleva Date: Thu, 9 Sep 2021 17:26:53 +0300 Subject: [PATCH] rpc: fill transaction witnesses during `invokescript` handling --- pkg/rpc/server/server.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/pkg/rpc/server/server.go b/pkg/rpc/server/server.go index 12a657034..20d632a1e 100644 --- a/pkg/rpc/server/server.go +++ b/pkg/rpc/server/server.go @@ -1281,11 +1281,12 @@ func (s *Server) invokescript(reqParams request.Params) (interface{}, *response. tx := &transaction.Transaction{} if len(reqParams) > 1 { - signers, _, err := reqParams[1].GetSignersWithWitnesses() + signers, witnesses, err := reqParams[1].GetSignersWithWitnesses() if err != nil { return nil, response.ErrInvalidParams } tx.Signers = signers + tx.Scripts = witnesses } if len(tx.Signers) == 0 { tx.Signers = []transaction.Signer{{Account: util.Uint160{}, Scopes: transaction.None}}