[Checkins] SVN: Products.ZCatalog/trunk/ Fixed inline `IISet` to `IITreeSet` conversion code inside DateRangeIndex' `_insertForwardIndexEntry` method.

Hanno Schlichting hannosch at hannosch.eu
Tue Jan 25 16:15:41 EST 2011


Log message for revision 119935:
  Fixed inline `IISet` to `IITreeSet` conversion code inside DateRangeIndex' `_insertForwardIndexEntry` method.
  

Changed:
  U   Products.ZCatalog/trunk/CHANGES.txt
  U   Products.ZCatalog/trunk/src/Products/PluginIndexes/DateRangeIndex/DateRangeIndex.py

-=-
Modified: Products.ZCatalog/trunk/CHANGES.txt
===================================================================
--- Products.ZCatalog/trunk/CHANGES.txt	2011-01-25 21:12:27 UTC (rev 119934)
+++ Products.ZCatalog/trunk/CHANGES.txt	2011-01-25 21:15:40 UTC (rev 119935)
@@ -4,6 +4,8 @@
 2.13.4 (unreleased)
 -------------------
 
+- Fixed inline `IISet` to `IITreeSet` conversion code inside DateRangeIndex'
+  `_insertForwardIndexEntry` method.
 
 2.13.3 (2011-01-01)
 -------------------

Modified: Products.ZCatalog/trunk/src/Products/PluginIndexes/DateRangeIndex/DateRangeIndex.py
===================================================================
--- Products.ZCatalog/trunk/src/Products/PluginIndexes/DateRangeIndex/DateRangeIndex.py	2011-01-25 21:12:27 UTC (rev 119934)
+++ Products.ZCatalog/trunk/src/Products/PluginIndexes/DateRangeIndex/DateRangeIndex.py	2011-01-25 21:15:40 UTC (rev 119935)
@@ -326,8 +326,11 @@
         if treeset is None:
             tree[key] = value
         else:
-            if isinstance(treeset, (int, IISet)):
+            if isinstance(treeset, int):
                 tree[key] = IITreeSet((treeset, value))
+            elif isinstance(treeset, IISet):
+                tree[key] = IITreeSet(treeset)
+                tree[key].insert(value)
             else:
                 treeset.insert(value)
 



More information about the checkins mailing list