mirror of
https://github.com/bitcoin/bitcoin.git
synced 2026-06-07 21:28:40 +02:00
Merge #9853: Fix error codes from various RPCs
adaa281Update release notes to include RPC error code changes. (John Newbery)338bf06Add commenting around JSON error codes (John Newbery)dab804cReturn correct error codes in fundrawtransaction(). (John Newbery)a012087Return correct error codes in setban(). (John Newbery)960bc7fReturn correct error codes in removeprunedfunds(). (John Newbery)c119096Return correct error codes in blockchain.cpp. (John Newbery)6d07c62Return correct error codes in bumpfee(). (John Newbery) Tree-SHA512: 4bb39ad221cd8c83d98ac5d7ad642f3a8c265522720dc86b2eebc70e74439a85b06d6ddcd6a874e879d986511de3ab0878bb7fe58b50cb0546b78913632ea809
This commit is contained in:
@@ -348,11 +348,11 @@ UniValue removeprunedfunds(const JSONRPCRequest& request)
|
||||
std::vector<uint256> vHashOut;
|
||||
|
||||
if (pwallet->ZapSelectTx(vHash, vHashOut) != DB_LOAD_OK) {
|
||||
throw JSONRPCError(RPC_INTERNAL_ERROR, "Could not properly delete the transaction.");
|
||||
throw JSONRPCError(RPC_WALLET_ERROR, "Could not properly delete the transaction.");
|
||||
}
|
||||
|
||||
if(vHashOut.empty()) {
|
||||
throw JSONRPCError(RPC_INTERNAL_ERROR, "Transaction does not exist in wallet.");
|
||||
throw JSONRPCError(RPC_INVALID_PARAMETER, "Transaction does not exist in wallet.");
|
||||
}
|
||||
|
||||
return NullUniValue;
|
||||
|
||||
Reference in New Issue
Block a user