aboutsummaryrefslogtreecommitdiff
path: root/src/wallet/rpcdump.cpp
diff options
context:
space:
mode:
authorLuke Dashjr <luke-jr+git@utopios.org>2020-02-21 21:52:52 +0000
committerLuke Dashjr <luke-jr+git@utopios.org>2020-04-02 16:00:28 +0000
commitb86cd155f6f661052042048aa7cfc2a397afe4f7 (patch)
tree3a37177aff374ce8a0936622701c7cf53aa2de5d /src/wallet/rpcdump.cpp
parent41fa2926d86a57c9623d34debef20746ee2f454a (diff)
downloadbitcoin-b86cd155f6f661052042048aa7cfc2a397afe4f7.tar.xz
scripted-diff: Wallet: Rename mapAddressBook to m_address_book
Previous versions assumed absence of an entry in mapAddressBook indicated change. This no longer holds true (due to bugs) and will shortly be made intentional. Renaming the field helps ensure that old code using mapAddressBook directly gets checked for necessary rebasing. -BEGIN VERIFY SCRIPT- sed -i -e 's/mapAddressBook/m_address_book/g' $(git grep -l 'mapAddressBook' ./src) -END VERIFY SCRIPT-
Diffstat (limited to 'src/wallet/rpcdump.cpp')
-rw-r--r--src/wallet/rpcdump.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/wallet/rpcdump.cpp b/src/wallet/rpcdump.cpp
index e4d0a3fa6d..1348f6091b 100644
--- a/src/wallet/rpcdump.cpp
+++ b/src/wallet/rpcdump.cpp
@@ -60,12 +60,12 @@ static bool GetWalletAddressesForKey(LegacyScriptPubKeyMan* spk_man, const CWall
CKey key;
spk_man->GetKey(keyid, key);
for (const auto& dest : GetAllDestinationsForKey(key.GetPubKey())) {
- if (pwallet->mapAddressBook.count(dest)) {
+ if (pwallet->m_address_book.count(dest)) {
if (!strAddr.empty()) {
strAddr += ",";
}
strAddr += EncodeDestination(dest);
- strLabel = EncodeDumpString(pwallet->mapAddressBook.at(dest).name);
+ strLabel = EncodeDumpString(pwallet->m_address_book.at(dest).name);
fLabelFound = true;
}
}
@@ -168,7 +168,7 @@ UniValue importprivkey(const JSONRPCRequest& request)
// label all new addresses, and label existing addresses if a
// label was passed.
for (const auto& dest : GetAllDestinationsForKey(pubkey)) {
- if (!request.params[1].isNull() || pwallet->mapAddressBook.count(dest) == 0) {
+ if (!request.params[1].isNull() || pwallet->m_address_book.count(dest) == 0) {
pwallet->SetAddressBook(dest, strLabel, "receive");
}
}