mirror of
https://github.com/btcsuite/btcd.git
synced 2026-08-13 12:32:51 +02:00
rpcserver: return the plain reject reason from btcd
This commit changes the `RejectReason` resulted from calling btcd's `testmempoolaccept` to be un-matched, leaving it to the caller to decide when and where to match it.
This commit is contained in:
parent
36683e0b96
commit
8abf969c3c
1 changed files with 1 additions and 4 deletions
|
|
@ -39,7 +39,6 @@ import (
|
|||
"github.com/btcsuite/btcd/mining"
|
||||
"github.com/btcsuite/btcd/mining/cpuminer"
|
||||
"github.com/btcsuite/btcd/peer"
|
||||
"github.com/btcsuite/btcd/rpcclient"
|
||||
"github.com/btcsuite/btcd/txscript"
|
||||
"github.com/btcsuite/btcd/wire"
|
||||
"github.com/btcsuite/websocket"
|
||||
|
|
@ -3858,9 +3857,7 @@ func handleTestMempoolAccept(s *rpcServer, cmd interface{},
|
|||
|
||||
// TODO(yy): differentiate the errors and put package
|
||||
// error in `PackageError` field.
|
||||
item.RejectReason = rpcclient.MapBtcdErrToRejectReason(
|
||||
err,
|
||||
)
|
||||
item.RejectReason = err.Error()
|
||||
|
||||
results = append(results, item)
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue