summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRichard Maudsley <richard.maudsley@isode.com>2014-05-29 13:34:06 (GMT)
committerSwift Review <review@swift.im>2014-05-30 10:58:54 (GMT)
commitbe915da04068a412dd63a597192ec3232ad4e1c2 (patch)
treedd84cbe8ee83e8706aaef2d5eb5924a65b17b26c /Swift/Controllers
parent3bc016cc6e477ef653970564b74948dc62b7022a (diff)
downloadswift-be915da04068a412dd63a597192ec3232ad4e1c2.zip
swift-be915da04068a412dd63a597192ec3232ad4e1c2.tar.bz2
Fix avatar not being updated when cleared
Change-Id: I4cf2d1d5500d0f50fbbcb455525123e9aa1ed948
Diffstat (limited to 'Swift/Controllers')
-rw-r--r--Swift/Controllers/Storages/VCardFileStorage.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/Swift/Controllers/Storages/VCardFileStorage.cpp b/Swift/Controllers/Storages/VCardFileStorage.cpp
index b22e235..b101ecf 100644
--- a/Swift/Controllers/Storages/VCardFileStorage.cpp
+++ b/Swift/Controllers/Storages/VCardFileStorage.cpp
@@ -88,7 +88,7 @@ std::string VCardFileStorage::getPhotoHash(const JID& jid) const {
std::string VCardFileStorage::getAndUpdatePhotoHash(const JID& jid, VCard::ref vCard) const {
std::string hash;
- if (vCard && !vCard->getPhoto().empty()) {
+ if (vCard) {
hash = Hexify::hexify(crypto->getSHA1Hash(vCard->getPhoto()));
}
std::pair<PhotoHashMap::iterator, bool> r = photoHashes.insert(std::make_pair(jid, hash));