aboutsummaryrefslogtreecommitdiff
path: root/plugins/omemo/src/own_notifications.vala
diff options
context:
space:
mode:
authorSamuel Hand <samuel.hand@openmailbox.org>2018-08-10 00:45:22 +0100
committerSamuel Hand <samuel.hand@openmailbox.org>2018-08-10 00:45:22 +0100
commit36cc8b039338442512f0e86d9487d951b5f2c6e3 (patch)
tree0313a349ed15b31a68fd657f07fae9810579c6f1 /plugins/omemo/src/own_notifications.vala
parente1afda10e33bdd892ee655cda7b94c066d269817 (diff)
downloaddino-36cc8b039338442512f0e86d9487d951b5f2c6e3.tar.gz
dino-36cc8b039338442512f0e86d9487d951b5f2c6e3.zip
Code cleanup - move long database queries to their own functions and improve variable names
Diffstat (limited to 'plugins/omemo/src/own_notifications.vala')
-rw-r--r--plugins/omemo/src/own_notifications.vala2
1 files changed, 1 insertions, 1 deletions
diff --git a/plugins/omemo/src/own_notifications.vala b/plugins/omemo/src/own_notifications.vala
index e1095c68..fbdb7e84 100644
--- a/plugins/omemo/src/own_notifications.vala
+++ b/plugins/omemo/src/own_notifications.vala
@@ -26,7 +26,7 @@ public class OwnNotifications {
}
public bool has_new_devices(Jid jid) {
- return plugin.db.identity_meta.with_address(account.id, jid.bare_jid.to_string()).with(plugin.db.identity_meta.trust_level, "=", Database.IdentityMetaTable.TrustLevel.UNKNOWN).without_null(plugin.db.identity_meta.identity_key_public_base64).count() > 0;
+ return plugin.db.identity_meta.get_new_devices(account.id, jid.bare_jid.to_string()).count() > 0;
}
private void display_notification() {