Commit 076ddfb2 authored by Vincent Pelletier's avatar Vincent Pelletier

Base: Restore lost check of self.isIndexable .

This check got lost when the first isSubtreeIndexable call was done on
parent document and not on self.
parent ed452b33
...@@ -2824,13 +2824,12 @@ class Base( CopyContainer, ...@@ -2824,13 +2824,12 @@ class Base( CopyContainer,
ancestry: a document may only be indexed if its parent is indexable, and ancestry: a document may only be indexed if its parent is indexable, and
it's parent's parent, etc until ERP5Site object (inclusive). it's parent's parent, etc until ERP5Site object (inclusive).
""" """
node = self.aq_inner.aq_parent node = self.aq_inner
portal = aq_base(self.getPortalObject()) portal = aq_base(self.getPortalObject())
while True: is_indexable = self.isIndexable
is_indexable = node.isSubtreeIndexable() while is_indexable and aq_base(node) is not portal:
if not is_indexable or aq_base(node) is portal:
break
node = node.aq_parent node = node.aq_parent
is_indexable = node.isSubtreeIndexable()
return is_indexable return is_indexable
security.declarePrivate('immediateReindexObject') security.declarePrivate('immediateReindexObject')
......
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