Commit f5f7e4f6 authored by Arnaud Fontaine's avatar Arnaud Fontaine

Prevent infinite recursion when solving dependency on installation of

Business Template portal types


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@40635 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 7581e80f
...@@ -1896,6 +1896,8 @@ class PortalTypeTemplateItem(ObjectTemplateItem): ...@@ -1896,6 +1896,8 @@ class PortalTypeTemplateItem(ObjectTemplateItem):
else: else:
portal_type = klass.__name__ portal_type = klass.__name__
depend = path_dict.get(portal_type) depend = path_dict.get(portal_type)
# Prevent infinite recursion
assert depend != path
cache[path] = score = depend and 1 + solveDependency(depend)[0] or 0 cache[path] = score = depend and 1 + solveDependency(depend)[0] or 0
return score, path return score, path
PersistentMigrationMixin._no_migration += 1 PersistentMigrationMixin._no_migration += 1
......
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