Commit c514befe authored by wenjie.zheng's avatar wenjie.zheng

Interaction: fix guard creation condiction to avoid guard conflict.

parent 701c7f30
......@@ -99,14 +99,13 @@ class Interaction(IdAsReferenceMixin('interaction_', "prefix"), XMLObject):
self.getGroupList() is None and\
self.getExpression() is None and\
self.guard is None:
return None
else:
return Guard().__of__(self)
elif self.guard is None:
self.generateGuard()
return self.guard
def generateGuard(self):
if self.guard is None:
self.guard = Guard().__of__(self)
self.guard = Guard()
if self.getRoleList() is not None:
self.guard.roles = self.getRoleList()
if self.getPermissionList() is not None:
......
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