From c03411b22f9a9beffaa6077be0ab3440200e8ff7 Mon Sep 17 00:00:00 2001 From: Stephen Paul Weber Date: Tue, 24 Nov 2015 16:53:29 -0500 Subject: [PATCH] Return errors to SMS user --- Main.hs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Main.hs b/Main.hs index c0326cd..b4b6d68 100644 --- a/Main.hs +++ b/Main.hs @@ -216,8 +216,8 @@ viteltiy db toVitelity toComponent = do messageID = Just $ fromString ("CHEOGRAM%" <> fromMaybe "UUIDFAIL" uuid), messagePayloads = [Element (fromString "{jabber:component:accept}body") [] [NodeContent $ ContentText msg]] } - Nothing -> print "ERROR: trying to send, but no room joined" - Nothing -> print "ERROR: no command parsed" + Nothing -> writeStanzaChan toVitelity $ mkSMS tel (fromString "You are not joined to a room") + Nothing -> writeStanzaChan toVitelity $ mkSMS tel (fromString "You sent an invalid message") _ -> return () openTokyoCabinet :: (TC.TCDB a) => FilePath -> IO a -- 2.38.5