Commit 0ae01ef3 authored by Nicolas Dumazet's avatar Nicolas Dumazet

Fix issue when an XMLMatrix has child objects that are not Cells:

in this case _checkConsistency should not examine those children objects.
It might be better to filter portal types directly in contentValues.


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@33648 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent ca8a5d79
......@@ -646,7 +646,8 @@ class XMLMatrix(Folder):
# the last item is a coordinate not part of base_id
object_id_split.pop()
if base_id is not None:
current_dimension = len(cell_coordinate_list)
if current_dimension > 0 and base_id is not None:
if not self.index.has_key(base_id):
# The matrix does not have this base_id
addError("There is no index for base_id %s" % base_id)
......@@ -665,7 +666,6 @@ class XMLMatrix(Folder):
del base_item[key]
len_id = len(base_item)
current_dimension = len(cell_coordinate_list)
if current_dimension != len_id:
addError("Dimension of cell is %s but should be %s" % (current_dimension,
len_id))
......
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