rpc/server: return original error for invoke* param errors
This commit is contained in:
parent
7f8b259994
commit
7b1943a6e5
1 changed files with 2 additions and 2 deletions
|
@ -1675,7 +1675,7 @@ func (s *Server) getInvokeScriptParams(reqParams request.Params) (*transaction.T
|
||||||
if len(reqParams) > 1 {
|
if len(reqParams) > 1 {
|
||||||
signers, witnesses, err := reqParams[1].GetSignersWithWitnesses()
|
signers, witnesses, err := reqParams[1].GetSignersWithWitnesses()
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, false, response.ErrInvalidParams
|
return nil, false, response.WrapErrorWithData(response.ErrInvalidParams, err)
|
||||||
}
|
}
|
||||||
tx.Signers = signers
|
tx.Signers = signers
|
||||||
tx.Scripts = witnesses
|
tx.Scripts = witnesses
|
||||||
|
@ -1684,7 +1684,7 @@ func (s *Server) getInvokeScriptParams(reqParams request.Params) (*transaction.T
|
||||||
if len(reqParams) > 2 {
|
if len(reqParams) > 2 {
|
||||||
verbose, err = reqParams[2].GetBoolean()
|
verbose, err = reqParams[2].GetBoolean()
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, false, response.ErrInvalidParams
|
return nil, false, response.WrapErrorWithData(response.ErrInvalidParams, err)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if len(tx.Signers) == 0 {
|
if len(tx.Signers) == 0 {
|
||||||
|
|
Loading…
Reference in a new issue