summaryrefslogtreecommitdiff
path: root/Presence/EventUtil.hs
diff options
context:
space:
mode:
authorjoe <joe@jerkface.net>2014-02-14 23:39:33 -0500
committerjoe <joe@jerkface.net>2014-02-14 23:39:33 -0500
commit74def56dfa4e7361d12f27f09fb0f754109c23b5 (patch)
tree55f72aa86bdba1a40e66f79e1599ac8c3f74f517 /Presence/EventUtil.hs
parent9beb2a108ee13e95f71b1c5d0bdce4263caef84c (diff)
client connections
Diffstat (limited to 'Presence/EventUtil.hs')
-rw-r--r--Presence/EventUtil.hs6
1 files changed, 6 insertions, 0 deletions
diff --git a/Presence/EventUtil.hs b/Presence/EventUtil.hs
index a1c48e33..adcae1d3 100644
--- a/Presence/EventUtil.hs
+++ b/Presence/EventUtil.hs
@@ -29,6 +29,12 @@ isServerIQOf (EventBeginElement name attrs) testType
29 = True 29 = True
30isServerIQOf _ _ = False 30isServerIQOf _ _ = False
31 31
32isClientIQOf (EventBeginElement name attrs) testType
33 | name=="{jabber:client}iq"
34 && matchAttrib "type" testType attrs
35 = True
36isClientIQOf _ _ = False
37
32matchAttrib name value attrs = 38matchAttrib name value attrs =
33 case List.find ( (==name) . fst) attrs of 39 case List.find ( (==name) . fst) attrs of
34 Just (_,[ContentText x]) | x==value -> True 40 Just (_,[ContentText x]) | x==value -> True