mirror of
https://github.com/ElementsProject/elements.git
synced 2026-08-19 13:27:35 +02:00
rpc: avoid copying into UniValue
These are simple (and hopefully obviously correct) copies that can be moves instead.
This commit is contained in:
parent
ecd23656db
commit
d7707d9843
27 changed files with 183 additions and 183 deletions
|
|
@ -72,11 +72,11 @@ static RPCHelpMan validateaddress()
|
|||
ret.pushKV("scriptPubKey", HexStr(scriptPubKey));
|
||||
|
||||
UniValue detail = DescribeAddress(dest);
|
||||
ret.pushKVs(detail);
|
||||
ret.pushKVs(std::move(detail));
|
||||
} else {
|
||||
UniValue error_indices(UniValue::VARR);
|
||||
for (int i : error_locations) error_indices.push_back(i);
|
||||
ret.pushKV("error_locations", error_indices);
|
||||
ret.pushKV("error_locations", std::move(error_indices));
|
||||
ret.pushKV("error", error_msg);
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue