Refactor: CAddressBookData for mapAddressBook

Straight refactor, so mapAddressBook stores a CAddressBookData
(which just contains a std::string) instead of a std::string.

Preparation for payment protocol work, which will add the notion
of refund addresses to the address book.
This commit is contained in:
Gavin Andresen
2013-07-15 15:20:50 +10:00
parent b94595bb7f
commit 618855133d
9 changed files with 54 additions and 38 deletions

View File

@@ -229,7 +229,7 @@ Value listunspent(const Array& params, bool fHelp)
{
entry.push_back(Pair("address", CBitcoinAddress(address).ToString()));
if (pwalletMain->mapAddressBook.count(address))
entry.push_back(Pair("account", pwalletMain->mapAddressBook[address]));
entry.push_back(Pair("account", pwalletMain->mapAddressBook[address].name));
}
entry.push_back(Pair("scriptPubKey", HexStr(pk.begin(), pk.end())));
if (pk.IsPayToScriptHash())