Commit 5ddf02c7 authored by Kazuhiko Shiozaki's avatar Kazuhiko Shiozaki

fix checkConsistency return value for BTree inconsistency case.

parent 5ecb1625
...@@ -42,6 +42,7 @@ from Products.CMFCore.CMFCatalogAware import CMFCatalogAware ...@@ -42,6 +42,7 @@ from Products.CMFCore.CMFCatalogAware import CMFCatalogAware
from Products.CMFCore.PortalFolder import ContentFilter from Products.CMFCore.PortalFolder import ContentFilter
from Products.ERP5Type.Base import Base from Products.ERP5Type.Base import Base
from Products.ERP5Type.ConsistencyMessage import ConsistencyMessage
from Products.ERP5Type.CopySupport import CopyContainer from Products.ERP5Type.CopySupport import CopyContainer
from Products.ERP5Type import PropertySheet from Products.ERP5Type import PropertySheet
from Products.ERP5Type.XMLExportImport import Folder_asXML from Products.ERP5Type.XMLExportImport import Folder_asXML
...@@ -1426,8 +1427,8 @@ class Folder(CopyContainer, CMFBTreeFolder, CMFHBTreeFolder, Base, FolderMixIn): ...@@ -1426,8 +1427,8 @@ class Folder(CopyContainer, CMFBTreeFolder, CMFHBTreeFolder, Base, FolderMixIn):
if not btree_ok: if not btree_ok:
# We must commit if we want to keep on recursing # We must commit if we want to keep on recursing
transaction.savepoint(optimistic=True) transaction.savepoint(optimistic=True)
error_list += [(self.getRelativeUrl(), 'BTree Inconsistency', error_list += [ConsistencyMessage(
199, '(fixed)')] self, self.getRelativeUrl(), 'BTree Inconsistency (fixed)')]
# Call superclass # Call superclass
error_list += Base.checkConsistency(self, fixit=fixit, filter=filter, **kw) error_list += Base.checkConsistency(self, fixit=fixit, filter=filter, **kw)
# We must commit before listing folder contents # We must commit before listing folder contents
......
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