From adb5f645bc9f2fe38601a515b558a1b7e7819046 Mon Sep 17 00:00:00 2001 From: neiljp Date: Tue, 23 May 2017 18:28:10 -0700 Subject: [PATCH] contrib_bots: Update xkcd bot to use send_reply. This enables private message usage. --- contrib_bots/bots/xkcd/xkcd.py | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/contrib_bots/bots/xkcd/xkcd.py b/contrib_bots/bots/xkcd/xkcd.py index 144cc18..6a4dcce 100644 --- a/contrib_bots/bots/xkcd/xkcd.py +++ b/contrib_bots/bots/xkcd/xkcd.py @@ -29,13 +29,7 @@ class XkcdHandler(object): def handle_message(self, message, client, state_handler): xkcd_bot_response = get_xkcd_bot_response(message) - - client.send_message(dict( - type='stream', - to=message['display_recipient'], - subject=message['subject'], - content=xkcd_bot_response, - )) + client.send_reply(message, xkcd_bot_response) class XkcdBotCommand(object): LATEST = 0