summaryrefslogtreecommitdiff
path: root/qt4/TelepathyQt4/account-set.cpp
diff options
context:
space:
mode:
authorAndre Moreira Magalhaes (andrunko) <andre.magalhaes@collabora.co.uk>2010-07-30 03:49:27 -0300
committerAndre Moreira Magalhaes (andrunko) <andre.magalhaes@collabora.co.uk>2010-07-30 03:49:39 -0300
commitdb01e0c71443e4ffb350be474555e82180b02a26 (patch)
tree7da84c14d1fb456109ad207410151f69055f8935 /qt4/TelepathyQt4/account-set.cpp
parent08914d9a914b820f7c351cb7b1e543959c0af162 (diff)
parentc133d866aaae05e7d8496806c8337d80eecbbf47 (diff)
Merge remote branch 'wjt/new-account-removed'
Reviewed-by: Andre Moreira Magalhaes (andrunko) <andre.magalhaes@collabora.co.uk>
Diffstat (limited to 'qt4/TelepathyQt4/account-set.cpp')
-rw-r--r--qt4/TelepathyQt4/account-set.cpp9
1 files changed, 5 insertions, 4 deletions
diff --git a/qt4/TelepathyQt4/account-set.cpp b/qt4/TelepathyQt4/account-set.cpp
index 806da00ca..aa8163f49 100644
--- a/qt4/TelepathyQt4/account-set.cpp
+++ b/qt4/TelepathyQt4/account-set.cpp
@@ -122,10 +122,11 @@ void AccountSet::Private::filterAccount(const AccountPtr &account)
}
}
} else {
- /* QHash::remove is no-op if the item is not in the hash */
- accounts.remove(account->objectPath());
- if (ready) {
- emit parent->accountRemoved(account);
+ if (accounts.contains(account->objectPath())) {
+ accounts.remove(account->objectPath());
+ if (ready) {
+ emit parent->accountRemoved(account);
+ }
}
}
}