From 402981a6b18d3c7bca3dae7d4f67382cf3c9e0eb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sybren=20A=2E=20St=C3=BCvel?= Date: Fri, 6 May 2016 19:11:21 +0200 Subject: [PATCH] Small fixes --- pillar/application/utils/authorization.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pillar/application/utils/authorization.py b/pillar/application/utils/authorization.py index 5ef21479..053d6bf3 100644 --- a/pillar/application/utils/authorization.py +++ b/pillar/application/utils/authorization.py @@ -164,7 +164,7 @@ def merge_permissions(*args): for key in maybe_sorted(keys): methods0 = asdict0.get(key, []) methods1 = asdict1.get(key, []) - methods = maybe_sorted(set(methods0 + methods1)) + methods = maybe_sorted(set(methods0).union(set(methods1))) effective.setdefault(plural_name, []).append({field_name: key, u'methods': methods}) merge(u'user') @@ -173,7 +173,7 @@ def merge_permissions(*args): # Gather permissions for world world0 = args[0].get('world', []) world1 = args[1].get('world', []) - world_methods = set(world0 + world1) + world_methods = set(world0).union(set(world1)) if world_methods: effective[u'world'] = maybe_sorted(world_methods)