mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-11-12 23:18:14 +01:00
wallet: IsSpent, 'COutPoint' arg instead of (hash, index)
This commit is contained in:
@@ -1387,7 +1387,7 @@ RPCHelpMan sendall()
|
||||
throw JSONRPCError(RPC_INVALID_PARAMETER, "Cannot combine send_max with specific inputs.");
|
||||
} else if (options.exists("inputs")) {
|
||||
for (const CTxIn& input : rawTx.vin) {
|
||||
if (pwallet->IsSpent(input.prevout.hash, input.prevout.n)) {
|
||||
if (pwallet->IsSpent(input.prevout)) {
|
||||
throw JSONRPCError(RPC_INVALID_PARAMETER, strprintf("Input not available. UTXO (%s:%d) was already spent.", input.prevout.hash.ToString(), input.prevout.n));
|
||||
}
|
||||
const CWalletTx* tx{pwallet->GetWalletTx(input.prevout.hash)};
|
||||
|
||||
Reference in New Issue
Block a user