aboutsummaryrefslogtreecommitdiff
path: root/xmpp-vala/src/module/presence
diff options
context:
space:
mode:
authorfiaxh <git@lightrise.org>2022-01-04 20:06:43 +0100
committerfiaxh <git@lightrise.org>2022-01-04 21:45:45 +0100
commitc70201080b9bf432b9b7be2a88fd3cb6efa781b8 (patch)
tree76480ef1b25182b5d4df3b6a321615c20831ff27 /xmpp-vala/src/module/presence
parent33104a778d6bcfb37577d14d28f68442467636a9 (diff)
downloaddino-c70201080b9bf432b9b7be2a88fd3cb6efa781b8.tar.gz
dino-c70201080b9bf432b9b7be2a88fd3cb6efa781b8.zip
Create a new list to return in Presence.Flag.get_resources
Diffstat (limited to 'xmpp-vala/src/module/presence')
-rw-r--r--xmpp-vala/src/module/presence/flag.vala3
1 files changed, 3 insertions, 0 deletions
diff --git a/xmpp-vala/src/module/presence/flag.vala b/xmpp-vala/src/module/presence/flag.vala
index 8e13d0ad..cc0a1f6b 100644
--- a/xmpp-vala/src/module/presence/flag.vala
+++ b/xmpp-vala/src/module/presence/flag.vala
@@ -13,6 +13,9 @@ public class Flag : XmppStreamFlag {
}
public Gee.List<Jid>? get_resources(Jid jid) {
+ if (!resources.has_key(jid)) return null;
+ ArrayList<Jid> ret = new ArrayList<Jid>();
+ ret.add_all(resources[jid]);
return resources[jid];
}