formdata: fix substitution variables when workflow_roles is None (#6058)

This commit is contained in:
Frédéric Péters 2014-12-03 20:36:22 +01:00
parent e89377a842
commit 4ee347afc5
1 changed files with 3 additions and 1 deletions

View File

@ -363,7 +363,9 @@ class FormData(StorableObject):
# include substitution variables for workflow roles; this will
# typically give variables such as form_role_receiver_name and
# form_role_receiver_emails.
workflow_roles = self.formdef.workflow_roles.copy()
workflow_roles = {}
if self.formdef.workflow_roles:
workflow_roles.update(self.formdef.workflow_roles)
if self.workflow_roles:
workflow_roles.update(self.workflow_roles)