changeset 258:e5b83fbb0219

removed notifications when no items are allowed for an entity
author Goffi <goffi@goffi.org>
date Sun, 28 Apr 2013 19:29:58 +0200
parents 30988781f30d
children 6fe7da6b4b32
files sat_pubsub/backend.py
diffstat 1 files changed, 2 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/sat_pubsub/backend.py	Sun Apr 28 19:29:13 2013 +0200
+++ b/sat_pubsub/backend.py	Sun Apr 28 19:29:58 2013 +0200
@@ -760,7 +760,8 @@
                     else: #unknown access_model
                         raise NotImplementedError
 
-                notifications_filtered.append((subscriber, subscriptions, allowed_items))
+                if allowed_items:
+                    notifications_filtered.append((subscriber, subscriptions, allowed_items))
             
             #we notify the owner
             #FIXME: check if this comply with XEP-0060 (option needed ?)