Commit e733331f authored by Vincent Pelletier's avatar Vincent Pelletier

ERP5Type.Core.Folder: Fix recursive indexation of Trash Bins.

Since recent rework of isSubtreeIndexable, direct indexation of a trash bin
is fixed, but recursive indexation recursion condition broke: it stop just
above the trash bin instead of stopping just below it.
parent dd528bae
...@@ -1251,8 +1251,10 @@ class Folder(CopyContainer, OFSFolder2, CMFBTreeFolder, CMFHBTreeFolder, Base, F ...@@ -1251,8 +1251,10 @@ class Folder(CopyContainer, OFSFolder2, CMFBTreeFolder, CMFHBTreeFolder, Base, F
) )
def _isDocumentNonIndexable(self, document): def _isDocumentNonIndexable(self, document):
return (getattr(aq_base(document), 'isSubtreeIndexable', None) is None return (
or not document.isSubtreeIndexable()) getattr(aq_base(document), 'isAncestryIndexable', None) is None or
not document.isAncestryIndexable()
)
def _updateActivateKwWithSerialisationTag(self, document, activate_kw): def _updateActivateKwWithSerialisationTag(self, document, activate_kw):
activate_kw['serialization_tag'] = document.getRootDocumentPath() activate_kw['serialization_tag'] = document.getRootDocumentPath()
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment