aboutsummaryrefslogtreecommitdiff
path: root/src/wallet/rpc/backup.cpp
diff options
context:
space:
mode:
authorCory Fields <cory-nospam-@coryfields.com>2024-05-13 20:20:10 +0000
committerCory Fields <cory-nospam-@coryfields.com>2024-05-20 16:48:19 +0000
commitd7707d9843b03f20d2a8c5a45d7b3db58e169e6f (patch)
tree30b3b88003c41ef7521e1b2e7bbb6add06892505 /src/wallet/rpc/backup.cpp
parentecd23656db174adef61d3bd753d02698c3528192 (diff)
rpc: avoid copying into UniValue
These are simple (and hopefully obviously correct) copies that can be moves instead.
Diffstat (limited to 'src/wallet/rpc/backup.cpp')
-rw-r--r--src/wallet/rpc/backup.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/wallet/rpc/backup.cpp b/src/wallet/rpc/backup.cpp
index 8d3eea59ee..a76ae7196c 100644
--- a/src/wallet/rpc/backup.cpp
+++ b/src/wallet/rpc/backup.cpp
@@ -1827,16 +1827,16 @@ RPCHelpMan listdescriptors()
UniValue range(UniValue::VARR);
range.push_back(info.range->first);
range.push_back(info.range->second - 1);
- spk.pushKV("range", range);
+ spk.pushKV("range", std::move(range));
spk.pushKV("next", info.next_index);
spk.pushKV("next_index", info.next_index);
}
- descriptors.push_back(spk);
+ descriptors.push_back(std::move(spk));
}
UniValue response(UniValue::VOBJ);
response.pushKV("wallet_name", wallet->GetName());
- response.pushKV("descriptors", descriptors);
+ response.pushKV("descriptors", std::move(descriptors));
return response;
},