diff sat_pubsub/memory_storage.py @ 297:4115999d85e9

fixes behavior when maxItems is 0
author souliane <souliane@mailoo.org>
date Thu, 10 Sep 2015 15:03:12 +0200
parents 002c59dbc23f
children a776544d84e5
line wrap: on
line diff
--- a/sat_pubsub/memory_storage.py	Thu Sep 10 15:02:03 2015 +0200
+++ b/sat_pubsub/memory_storage.py	Thu Sep 10 15:03:12 2015 +0200
@@ -292,7 +292,7 @@
 
 
     def getItems(self, authorized_groups, unrestricted, maxItems=None):
-        if maxItems:
+        if maxItems is not None:
             itemList = self._itemlist[-maxItems:]
         else:
             itemList = self._itemlist