From aaa454126c5bccd2e12a156642e130a0b78103e8 Mon Sep 17 00:00:00 2001 From: Joe Crayne Date: Mon, 10 Sep 2018 03:49:15 -0400 Subject: xmpp2tox: Cancel status message when appropriate. --- XMPPToTox.hs | 3 +++ 1 file changed, 3 insertions(+) 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" when (not $ USERSTATUS `elem` xs) $ do -- Missing element means Available. yield $ TwoByte USERSTATUS $ jabberUserStatus Available + when (not $ STATUSMESSAGE `elem` xs) $ do + -- Missing implies empty status. + yield $ UpToN STATUSMESSAGE mempty unknownToTox :: MonadThrow m => ConduitM Event CryptoMessage m (Maybe ()) -- cgit v1.2.3