mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-03-05 14:06:27 -05:00
RPC: bugfix, 'add_inputs' default value is true unless 'inputs' are provided
In both RPC commands `send()` and `walletcreatefundedpsbt` the RPC help was saying that `add_inputs` default value was false when it's actually dynamically set by the following statement: `coin_control.m_allow_other_inputs = rawTx.vin.size() == 0;` Which means that, by default, `add_inputs` is true unless there was any pre-set input, in which case, the default is false.
This commit is contained in:
parent
3c5fb9691b
commit
ddbcfdf3d0
1 changed files with 2 additions and 2 deletions
|
@ -1137,7 +1137,7 @@ RPCHelpMan send()
|
||||||
{"options", RPCArg::Type::OBJ, RPCArg::Optional::OMITTED_NAMED_ARG, "",
|
{"options", RPCArg::Type::OBJ, RPCArg::Optional::OMITTED_NAMED_ARG, "",
|
||||||
Cat<std::vector<RPCArg>>(
|
Cat<std::vector<RPCArg>>(
|
||||||
{
|
{
|
||||||
{"add_inputs", RPCArg::Type::BOOL, RPCArg::Default{false}, "If inputs are specified, automatically include more if they are not enough."},
|
{"add_inputs", RPCArg::Type::BOOL, RPCArg::DefaultHint{"false when \"inputs\" are specified, true otherwise"},"Automatically include coins from the wallet to cover the target amount.\n"},
|
||||||
{"include_unsafe", RPCArg::Type::BOOL, RPCArg::Default{false}, "Include inputs that are not safe to spend (unconfirmed transactions from outside keys and unconfirmed replacement transactions).\n"
|
{"include_unsafe", RPCArg::Type::BOOL, RPCArg::Default{false}, "Include inputs that are not safe to spend (unconfirmed transactions from outside keys and unconfirmed replacement transactions).\n"
|
||||||
"Warning: the resulting transaction may become invalid if one of the unsafe inputs disappears.\n"
|
"Warning: the resulting transaction may become invalid if one of the unsafe inputs disappears.\n"
|
||||||
"If that happens, you will need to fund the transaction with different inputs and republish it."},
|
"If that happens, you will need to fund the transaction with different inputs and republish it."},
|
||||||
|
@ -1582,7 +1582,7 @@ RPCHelpMan walletcreatefundedpsbt()
|
||||||
{"options", RPCArg::Type::OBJ, RPCArg::Optional::OMITTED_NAMED_ARG, "",
|
{"options", RPCArg::Type::OBJ, RPCArg::Optional::OMITTED_NAMED_ARG, "",
|
||||||
Cat<std::vector<RPCArg>>(
|
Cat<std::vector<RPCArg>>(
|
||||||
{
|
{
|
||||||
{"add_inputs", RPCArg::Type::BOOL, RPCArg::Default{false}, "If inputs are specified, automatically include more if they are not enough."},
|
{"add_inputs", RPCArg::Type::BOOL, RPCArg::DefaultHint{"false when \"inputs\" are specified, true otherwise"}, "Automatically include coins from the wallet to cover the target amount.\n"},
|
||||||
{"include_unsafe", RPCArg::Type::BOOL, RPCArg::Default{false}, "Include inputs that are not safe to spend (unconfirmed transactions from outside keys and unconfirmed replacement transactions).\n"
|
{"include_unsafe", RPCArg::Type::BOOL, RPCArg::Default{false}, "Include inputs that are not safe to spend (unconfirmed transactions from outside keys and unconfirmed replacement transactions).\n"
|
||||||
"Warning: the resulting transaction may become invalid if one of the unsafe inputs disappears.\n"
|
"Warning: the resulting transaction may become invalid if one of the unsafe inputs disappears.\n"
|
||||||
"If that happens, you will need to fund the transaction with different inputs and republish it."},
|
"If that happens, you will need to fund the transaction with different inputs and republish it."},
|
||||||
|
|
Loading…
Add table
Reference in a new issue