From 189a091d677efc4da7ff608f58bdbc40df4daeca Mon Sep 17 00:00:00 2001 From: pocketjawa Date: Mon, 20 Mar 2017 18:36:36 -0400 Subject: [PATCH] make the bot ignore messages it sent --- pocketbot.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/pocketbot.py b/pocketbot.py index 730e7a9..6313a14 100644 --- a/pocketbot.py +++ b/pocketbot.py @@ -46,6 +46,10 @@ def on_ready(): @asyncio.coroutine def on_message(message): + #Ignore messages from self + if message.author == client.user: + return + #Maki Monday praise command if (message.content.lower().startswith('!maki')) or (message.content.lower().startswith('!monday')): yield from client.send_message(message.channel, 'http://maki.pocketjawa.com/monday.png')