Commit 4da01688 authored by Vincent Pelletier's avatar Vincent Pelletier

Avoid creating a PersistentMapping instance to just overwrite it at function end.


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@18544 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 42775c10
......@@ -191,12 +191,6 @@ class XMLMatrix(Folder):
if current_range == list(kw): # kw is a tuple
return
# We must make sure the base_id exists
# in the event of a matrix creation for example
if not self.index.has_key(base_id):
# Create an index for this base_id
self.index[base_id] = PersistentMapping()
# Recreate a new index for the new range defined in *kw
i = 0
for index_ids in kw:
......@@ -207,6 +201,7 @@ class XMLMatrix(Folder):
j += 1
i += 1
if self.index.has_key(base_id):
# Look at each dimension i of the previous index
for i in self.index[base_id].keys():
movement[i] = {}
......
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