Commit d637c634 authored by Aurel's avatar Aurel

don't fail at uninstall if we don't find the key


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@12860 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent b354a6f3
......@@ -663,8 +663,8 @@ class ObjectTemplateItem(BaseTemplateItem):
obj = obj._getCopy(container)
container._setObject(object_id, obj)
obj = container._getOb(object_id)
# mark a business template installation so in 'PortalType_afterClone' scripts
# we can implement logical for reseting or not attributes (i.e reference).
# mark a business template installation so in 'PortalType_afterClone' scripts
# we can implement logical for reseting or not attributes (i.e reference).
self.REQUEST.set('is_business_template_installation', 1)
obj.manage_afterClone(obj)
obj.wl_clearLocks()
......@@ -1887,10 +1887,12 @@ class CatalogMethodTemplateItem(ObjectTemplateItem):
else:
values = self._archive.values()
else:
value = self._archive[object_path]
try:
value = self._archive[object_path]
except KeyError:
value = None
if value is not None:
values.append(value)
for obj in values:
method_id = obj.id
# remove method references in portal_catalog
......
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