Improve error return from sendrawtransaction.

Rather than simply returning "TX rejected" to the RPC client which
submitted a sendrawtransaction that fails, include the reason the it
failed.
This commit is contained in:
Dave Collins 2014-03-17 17:33:56 -05:00
parent 7a885b3cf6
commit e5afb5e984

View file

@ -1399,7 +1399,7 @@ func handleSendRawTransaction(s *rpcServer, cmd btcjson.Cmd) (interface{}, error
}
err = btcjson.Error{
Code: btcjson.ErrDeserialization.Code,
Message: "TX rejected",
Message: fmt.Sprintf("TX rejected: %v", err),
}
return nil, err
}