Commit 6bb76065 authored by Aurel's avatar Aurel

return empty list instead of none when no property defined on portal type roles

remove trailling spaces


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@8391 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 9884ce43
......@@ -2005,7 +2005,7 @@ class PortalTypeRolesTemplateItem(BaseTemplateItem):
(property, prop_value)
# multi
for property in ('category', 'base_category'):
for prop_value in role.get(property):
for prop_value in role.get(property, []):
xml_data += os.linesep+" <multi_property "\
"id='%s'>%s</multi_property>" % (property, prop_value)
xml_data += os.linesep+" </role>"
......
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