From 990e7d5d8ed67b198377dfbb1abce5e48e595b7c Mon Sep 17 00:00:00 2001 From: jason Date: Thu, 18 Aug 2016 13:16:29 -0600 Subject: bug: disable messaging bots (from a bot) in slack --- warmachine/connections/slack.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/warmachine/connections/slack.py b/warmachine/connections/slack.py index 2f1a249..79c80a2 100644 --- a/warmachine/connections/slack.py +++ b/warmachine/connections/slack.py @@ -97,6 +97,11 @@ class SlackWS(Connection): destination = self.channel_name_to_id[destination.replace('#','')] else: _user = self.user_nick_to_id[destination] + + # slack doesn't allow bots to message other bots + if self.user_map[_user]['is_bot']: + return + destination = self.get_dm_id_by_user(_user) message = { -- cgit v1.2.1