Commit 06cf84e9 authored by Cédric Le Ninivin's avatar Cédric Le Ninivin

Fix KeyError on role without reference when building business templates

parent faee5904
......@@ -3056,6 +3056,7 @@ class PortalTypeRolesTemplateItem(BaseTemplateItem):
if not k:
continue
type_role_dict[k] = v
if 'id' in type_role_dict:
type_role_list.append(type_role_dict)
type_role_list.sort(key=lambda x: (x.get('title'), x['object_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