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:
@@ -214,10 +214,10 @@ WalletModel::SendCoinsReturn WalletModel::sendCoins(const QList<SendCoinsRecipie
|
||||
{
|
||||
LOCK(wallet->cs_wallet);
|
||||
|
||||
std::map<CTxDestination, std::string>::iterator mi = wallet->mapAddressBook.find(dest);
|
||||
std::map<CTxDestination, CAddressBookData>::iterator mi = wallet->mapAddressBook.find(dest);
|
||||
|
||||
// Check if we have a new address or an updated label
|
||||
if (mi == wallet->mapAddressBook.end() || mi->second != strLabel)
|
||||
if (mi == wallet->mapAddressBook.end() || mi->second.name != strLabel)
|
||||
{
|
||||
wallet->SetAddressBookName(dest, strLabel);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user