Skip to content

Commit 569c46c

Browse files
committed
Merge 6d00035 into merged_master (Elements PR #778)
2 parents 28623ac + 6d00035 commit 569c46c

File tree

2 files changed

+25
-25
lines changed

2 files changed

+25
-25
lines changed

src/wallet/rpcwallet.cpp

Lines changed: 24 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -217,7 +217,7 @@ static UniValue getnewaddress(const JSONRPCRequest& request)
217217
}
218218

219219
RPCHelpMan{"getnewaddress",
220-
"\nReturns a new Bitcoin address for receiving payments.\n"
220+
"\nReturns a new address for receiving payments.\n"
221221
"If 'label' is specified, it is added to the address book \n"
222222
"so payments received with the address will be associated with 'label'.\n"
223223
"When the wallet doesn't give blinded addresses by default (-blindedaddresses=0), \n"
@@ -227,7 +227,7 @@ static UniValue getnewaddress(const JSONRPCRequest& request)
227227
{"address_type", RPCArg::Type::STR, /* default */ "set by -addresstype", "The address type to use. Options are \"legacy\", \"p2sh-segwit\", and \"bech32\". Default is set by -addresstype."},
228228
},
229229
RPCResult{
230-
"\"address\" (string) The new bitcoin address\n"
230+
"\"address\" (string) The new address\n"
231231
},
232232
RPCExamples{
233233
HelpExampleCli("getnewaddress", "")
@@ -332,7 +332,7 @@ static UniValue setlabel(const JSONRPCRequest& request)
332332
RPCHelpMan{"setlabel",
333333
"\nSets the label associated with the given address.\n",
334334
{
335-
{"address", RPCArg::Type::STR, RPCArg::Optional::NO, "The bitcoin address to be associated with a label."},
335+
{"address", RPCArg::Type::STR, RPCArg::Optional::NO, "The address to be associated with a label."},
336336
{"label", RPCArg::Type::STR, RPCArg::Optional::NO, "The label to assign to the address."},
337337
},
338338
RPCResults{},
@@ -411,7 +411,7 @@ static UniValue sendtoaddress(const JSONRPCRequest& request)
411411
"\nSend an amount to a given address." +
412412
HelpRequiringPassphrase(pwallet) + "\n",
413413
{
414-
{"address", RPCArg::Type::STR, RPCArg::Optional::NO, "The bitcoin address to send to."},
414+
{"address", RPCArg::Type::STR, RPCArg::Optional::NO, "The address to send to."},
415415
{"amount", RPCArg::Type::AMOUNT, RPCArg::Optional::NO, "The amount in " + CURRENCY_UNIT + " to send. eg 0.1"},
416416
{"comment", RPCArg::Type::STR, RPCArg::Optional::OMITTED_NAMED_ARG, "A comment used to store what the transaction is for.\n"
417417
" This is not part of the transaction, just kept in your wallet."},
@@ -528,7 +528,7 @@ static UniValue listaddressgroupings(const JSONRPCRequest& request)
528528
"[\n"
529529
" [\n"
530530
" [\n"
531-
" \"address\", (string) The bitcoin address\n"
531+
" \"address\", (string) The address\n"
532532
" amount, (numeric) The amount in " + CURRENCY_UNIT + "\n"
533533
" \"label\" (string, optional) The label\n"
534534
" ]\n"
@@ -584,7 +584,7 @@ static UniValue signmessage(const JSONRPCRequest& request)
584584
"\nSign a message with the private key of an address" +
585585
HelpRequiringPassphrase(pwallet) + "\n",
586586
{
587-
{"address", RPCArg::Type::STR, RPCArg::Optional::NO, "The bitcoin address to use for the private key."},
587+
{"address", RPCArg::Type::STR, RPCArg::Optional::NO, "The address to use for the private key."},
588588
{"message", RPCArg::Type::STR, RPCArg::Optional::NO, "The message to create a signature of."},
589589
},
590590
RPCResult{
@@ -655,7 +655,7 @@ static UniValue getreceivedbyaddress(const JSONRPCRequest& request)
655655
RPCHelpMan{"getreceivedbyaddress",
656656
"\nReturns the total amount received by the given address in transactions with at least minconf confirmations.\n",
657657
{
658-
{"address", RPCArg::Type::STR, RPCArg::Optional::NO, "The bitcoin address for transactions."},
658+
{"address", RPCArg::Type::STR, RPCArg::Optional::NO, "The address for transactions."},
659659
{"minconf", RPCArg::Type::NUM, /* default */ "1", "Only include transactions confirmed at least this many times."},
660660
{"assetlabel", RPCArg::Type::STR, RPCArg::Optional::OMITTED_NAMED_ARG, "Hex asset id or asset label for balance."},
661661
},
@@ -921,7 +921,7 @@ static UniValue sendmany(const JSONRPCRequest& request)
921921
{"dummy", RPCArg::Type::STR, RPCArg::Optional::NO, "Must be set to \"\" for backwards compatibility.", "\"\""},
922922
{"amounts", RPCArg::Type::OBJ, RPCArg::Optional::NO, "A json object with addresses and amounts",
923923
{
924-
{"address", RPCArg::Type::AMOUNT, RPCArg::Optional::NO, "The bitcoin address is the key, the numeric amount (can be string) in " + CURRENCY_UNIT + " is the value"},
924+
{"address", RPCArg::Type::AMOUNT, RPCArg::Optional::NO, "The address is the key, the numeric amount (can be string) in " + CURRENCY_UNIT + " is the value"},
925925
},
926926
},
927927
{"minconf", RPCArg::Type::NUM, RPCArg::Optional::OMITTED_NAMED_ARG, "Ignored dummy value"},
@@ -1091,9 +1091,9 @@ static UniValue addmultisigaddress(const JSONRPCRequest& request)
10911091
"If 'label' is specified, assign address to that label.\n",
10921092
{
10931093
{"nrequired", RPCArg::Type::NUM, RPCArg::Optional::NO, "The number of required signatures out of the n keys or addresses."},
1094-
{"keys", RPCArg::Type::ARR, RPCArg::Optional::NO, "A json array of bitcoin addresses or hex-encoded public keys",
1094+
{"keys", RPCArg::Type::ARR, RPCArg::Optional::NO, "A json array of addresses or hex-encoded public keys",
10951095
{
1096-
{"key", RPCArg::Type::STR, RPCArg::Optional::OMITTED, "bitcoin address or hex-encoded public key"},
1096+
{"key", RPCArg::Type::STR, RPCArg::Optional::OMITTED, "address or hex-encoded public key"},
10971097
},
10981098
},
10991099
{"label", RPCArg::Type::STR, RPCArg::Optional::OMITTED_NAMED_ARG, "A label to assign the addresses to."},
@@ -1632,7 +1632,7 @@ UniValue listtransactions(const JSONRPCRequest& request)
16321632
"[\n"
16331633
" {\n"
16341634
" \"involvesWatchonly\": xxx, (bool) Only returns true if imported addresses were involved in transaction.\n"
1635-
" \"address\":\"address\", (string) The bitcoin address of the transaction.\n"
1635+
" \"address\":\"address\", (string) The address of the transaction.\n"
16361636
" \"category\": (string) The transaction category.\n"
16371637
" \"send\" Transactions sent.\n"
16381638
" \"receive\" Non-coinbase transactions received.\n"
@@ -1756,7 +1756,7 @@ static UniValue listsinceblock(const JSONRPCRequest& request)
17561756
"{\n"
17571757
" \"transactions\": [\n"
17581758
" \"involvesWatchonly\": xxx, (bool) Only returns true if imported addresses were involved in transaction.\n"
1759-
" \"address\":\"address\", (string) The bitcoin address of the transaction.\n"
1759+
" \"address\":\"address\", (string) The address of the transaction.\n"
17601760
" \"category\": (string) The transaction category.\n"
17611761
" \"send\" Transactions sent.\n"
17621762
" \"receive\" Non-coinbase transactions received.\n"
@@ -1895,7 +1895,7 @@ static UniValue gettransaction(const JSONRPCRequest& request)
18951895
+ " \"details\" : [\n"
18961896
" {\n"
18971897
" \"involvesWatchonly\": xxx, (bool) Only returns true if imported addresses were involved in transaction.\n"
1898-
" \"address\" : \"address\", (string) The bitcoin address involved in the transaction\n"
1898+
" \"address\" : \"address\", (string) The address involved in the transaction\n"
18991899
" \"category\" : (string) The transaction category.\n"
19001900
" \"send\" Transactions sent.\n"
19011901
" \"receive\" Non-coinbase transactions received.\n"
@@ -3037,9 +3037,9 @@ static UniValue listunspent(const JSONRPCRequest& request)
30373037
{
30383038
{"minconf", RPCArg::Type::NUM, /* default */ "1", "The minimum confirmations to filter"},
30393039
{"maxconf", RPCArg::Type::NUM, /* default */ "9999999", "The maximum confirmations to filter"},
3040-
{"addresses", RPCArg::Type::ARR, /* default */ "empty array", "A json array of bitcoin addresses to filter",
3040+
{"addresses", RPCArg::Type::ARR, /* default */ "empty array", "A json array of addresses to filter",
30413041
{
3042-
{"address", RPCArg::Type::STR, RPCArg::Optional::OMITTED, "bitcoin address"},
3042+
{"address", RPCArg::Type::STR, RPCArg::Optional::OMITTED, "address"},
30433043
},
30443044
},
30453045
{"include_unsafe", RPCArg::Type::BOOL, /* default */ "true", "Include outputs that are not safe to spend\n"
@@ -3059,7 +3059,7 @@ static UniValue listunspent(const JSONRPCRequest& request)
30593059
" {\n"
30603060
" \"txid\" : \"txid\", (string) the transaction id \n"
30613061
" \"vout\" : n, (numeric) the vout value\n"
3062-
" \"address\" : \"address\", (string) the bitcoin address\n"
3062+
" \"address\" : \"address\", (string) the address\n"
30633063
" \"label\" : \"label\", (string) The associated label, or \"\" for the default label\n"
30643064
" \"scriptPubKey\" : \"key\", (string) the script key\n"
30653065
" \"amount\" : x.xxx, (numeric) the transaction output amount in " + CURRENCY_UNIT + "\n"
@@ -3317,7 +3317,7 @@ void FundTransaction(CWallet* const pwallet, CMutableTransaction& tx, CAmount& f
33173317
// Single destination for default asset (policyAsset).
33183318
CTxDestination dest = DecodeDestination(options["changeAddress"].get_str());
33193319
if (!IsValidDestination(dest)) {
3320-
throw JSONRPCError(RPC_INVALID_ADDRESS_OR_KEY, "changeAddress must be a valid bitcoin address");
3320+
throw JSONRPCError(RPC_INVALID_ADDRESS_OR_KEY, "changeAddress must be a valid address");
33213321
}
33223322
destinations[::policyAsset] = dest;
33233323
} else if (options["changeAddress"].isObject()) {
@@ -3333,7 +3333,7 @@ void FundTransaction(CWallet* const pwallet, CMutableTransaction& tx, CAmount& f
33333333

33343334
CTxDestination dest = DecodeDestination(kv.second.get_str());
33353335
if (!IsValidDestination(dest)) {
3336-
throw JSONRPCError(RPC_INVALID_ADDRESS_OR_KEY, "changeAddress must be a valid bitcoin address");
3336+
throw JSONRPCError(RPC_INVALID_ADDRESS_OR_KEY, "changeAddress must be a valid address");
33373337
}
33383338

33393339
destinations[asset] = dest;
@@ -3444,7 +3444,7 @@ static UniValue fundrawtransaction(const JSONRPCRequest& request)
34443444
{"hexstring", RPCArg::Type::STR_HEX, RPCArg::Optional::NO, "The hex string of the raw transaction"},
34453445
{"options", RPCArg::Type::OBJ, RPCArg::Optional::OMITTED_NAMED_ARG, "for backward compatibility: passing in a true instead of an object will result in {\"includeWatching\":true}",
34463446
{
3447-
{"changeAddress", RPCArg::Type::STR, /* default */ "pool address", "The bitcoin address to receive the change"},
3447+
{"changeAddress", RPCArg::Type::STR, /* default */ "pool address", "The address to receive the change"},
34483448
{"changePosition", RPCArg::Type::NUM, /* default */ "random", "The index of the change output"},
34493449
{"change_type", RPCArg::Type::STR, /* default */ "set by -changetype", "The output type to use. Only valid if changeAddress is not specified. Options are \"legacy\", \"p2sh-segwit\", and \"bech32\"."},
34503450
{"includeWatching", RPCArg::Type::BOOL, /* default */ "true for watch-only wallets, otherwise false", "Also select inputs which are watch only.\n"
@@ -4106,14 +4106,14 @@ UniValue getaddressinfo(const JSONRPCRequest& request)
41064106
}
41074107

41084108
RPCHelpMan{"getaddressinfo",
4109-
"\nReturn information about the given bitcoin address. Some information requires the address\n"
4109+
"\nReturn information about the given address. Some information requires the address\n"
41104110
"to be in the wallet.\n",
41114111
{
4112-
{"address", RPCArg::Type::STR, RPCArg::Optional::NO, "The bitcoin address to get the information of."},
4112+
{"address", RPCArg::Type::STR, RPCArg::Optional::NO, "The address to get the information of."},
41134113
},
41144114
RPCResult{
41154115
"{\n"
4116-
" \"address\" : \"address\", (string) The bitcoin address validated\n"
4116+
" \"address\" : \"address\", (string) The address validated\n"
41174117
" \"scriptPubKey\" : \"hex\", (string) The hex-encoded scriptPubKey generated by the address\n"
41184118
" \"ismine\" : true|false, (boolean) If the address is yours or not\n"
41194119
" \"iswatchonly\" : true|false, (boolean) If the address is watchonly\n"
@@ -4646,7 +4646,7 @@ UniValue walletcreatefundedpsbt(const JSONRPCRequest& request)
46464646
{
46474647
{"", RPCArg::Type::OBJ, RPCArg::Optional::OMITTED, "",
46484648
{
4649-
{"address", RPCArg::Type::AMOUNT, RPCArg::Optional::NO, "A key-value pair. The key (string) is the bitcoin address, the value (float or string) is the amount in " + CURRENCY_UNIT + ""},
4649+
{"address", RPCArg::Type::AMOUNT, RPCArg::Optional::NO, "A key-value pair. The key (string) is the address, the value (float or string) is the amount in " + CURRENCY_UNIT + ""},
46504650
},
46514651
},
46524652
{"", RPCArg::Type::OBJ, RPCArg::Optional::OMITTED, "",
@@ -4659,7 +4659,7 @@ UniValue walletcreatefundedpsbt(const JSONRPCRequest& request)
46594659
{"locktime", RPCArg::Type::NUM, /* default */ "0", "Raw locktime. Non-0 value also locktime-activates inputs"},
46604660
{"options", RPCArg::Type::OBJ, RPCArg::Optional::OMITTED_NAMED_ARG, "",
46614661
{
4662-
{"changeAddress", RPCArg::Type::STR_HEX, /* default */ "pool address", "The bitcoin address to receive the change"},
4662+
{"changeAddress", RPCArg::Type::STR_HEX, /* default */ "pool address", "The address to receive the change"},
46634663
{"changePosition", RPCArg::Type::NUM, /* default */ "random", "The index of the change output"},
46644664
{"change_type", RPCArg::Type::STR, /* default */ "set by -changetype", "The output type to use. Only valid if changeAddress is not specified. Options are \"legacy\", \"p2sh-segwit\", and \"bech32\"."},
46654665
{"includeWatching", RPCArg::Type::BOOL, /* default */ "true for watch-only wallets, otherwise false", "Also select inputs which are watch only"},

test/functional/rpc_fundrawtransaction.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -230,7 +230,7 @@ def test_invalid_change_address(self):
230230
dec_tx = self.nodes[2].decoderawtransaction(rawtx)
231231
assert_equal(utx['txid'], dec_tx['vin'][0]['txid'])
232232

233-
assert_raises_rpc_error(-5, "changeAddress must be a valid bitcoin address", self.nodes[2].fundrawtransaction, rawtx, {'changeAddress':'foobar'})
233+
assert_raises_rpc_error(-5, "changeAddress must be a valid address", self.nodes[2].fundrawtransaction, rawtx, {'changeAddress':'foobar'})
234234

235235
def test_valid_change_address(self):
236236
self.log.info("Test fundrawtxn with a provided change address")

0 commit comments

Comments
 (0)