summaryrefslogtreecommitdiff
path: root/plugins/simple_notify.py
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/simple_notify.py')
-rw-r--r--plugins/simple_notify.py6
1 files changed, 5 insertions, 1 deletions
diff --git a/plugins/simple_notify.py b/plugins/simple_notify.py
index 9f35c437..60482101 100644
--- a/plugins/simple_notify.py
+++ b/plugins/simple_notify.py
@@ -104,6 +104,10 @@ class Plugin(BasePlugin):
self.do_notify(message, fro)
def on_highlight(self, message, tab):
+ whitelist = self.config.get('muc_list', '').split(':')
+ # prevents double notifications
+ if message['from'].bare in whitelist:
+ return
fro = message['from'].resource
self.do_notify(message, fro)
@@ -118,7 +122,7 @@ class Plugin(BasePlugin):
fro = message['from'].full
muc = message['from'].bare
- whitelist=self.config.get('muc_list', '').split(':')
+ whitelist = self.config.get('muc_list', '').split(':')
# Prevent old messages to be notified
# find_delayed_tag(message) returns (True, the datetime) or