aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--gui/src/clientmodel.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/gui/src/clientmodel.cpp b/gui/src/clientmodel.cpp
index 641c515ef..97b5f44fe 100644
--- a/gui/src/clientmodel.cpp
+++ b/gui/src/clientmodel.cpp
@@ -106,6 +106,11 @@ ClientModel::StatusCode ClientModel::sendCoins(const QString &payTo, qint64 payA
return MiscError;
}
}
+ // Add addresses that we've sent to to the address book
+ std::string strAddress = payTo.toStdString();
+ CRITICAL_BLOCK(cs_mapAddressBook)
+ if (!mapAddressBook.count(strAddress))
+ SetAddressBookName(strAddress, "");
return OK;
}