summaryrefslogtreecommitdiff
path: root/XMPPToTox.hs
diff options
context:
space:
mode:
authorJoe Crayne <joe@jerkface.net>2018-09-10 03:49:15 -0400
committerJoe Crayne <joe@jerkface.net>2018-09-21 18:18:58 -0400
commitaaa454126c5bccd2e12a156642e130a0b78103e8 (patch)
treeba3e8fd890968f272a8fcdb302e9e2821390f2a0 /XMPPToTox.hs
parent444f4b4ea199d1fda71fdd28c9b1826596214566 (diff)
xmpp2tox: Cancel status message when appropriate.
Diffstat (limited to 'XMPPToTox.hs')
-rw-r--r--XMPPToTox.hs3
1 files changed, 3 insertions, 0 deletions
diff --git a/XMPPToTox.hs b/XMPPToTox.hs
index d4da814c..b3372cfc 100644
--- a/XMPPToTox.hs
+++ b/XMPPToTox.hs
@@ -103,6 +103,9 @@ presenceToTox = tag' "{jabber:server}presence"
103 when (not $ USERSTATUS `elem` xs) $ do 103 when (not $ USERSTATUS `elem` xs) $ do
104 -- Missing <show> element means Available. 104 -- Missing <show> element means Available.
105 yield $ TwoByte USERSTATUS $ jabberUserStatus Available 105 yield $ TwoByte USERSTATUS $ jabberUserStatus Available
106 when (not $ STATUSMESSAGE `elem` xs) $ do
107 -- Missing <status> implies empty status.
108 yield $ UpToN STATUSMESSAGE mempty
106 109
107unknownToTox :: MonadThrow m => 110unknownToTox :: MonadThrow m =>
108 ConduitM Event CryptoMessage m (Maybe ()) 111 ConduitM Event CryptoMessage m (Maybe ())