Skip to content

Commit

Permalink
[#2939] Sysadmins have all the permissions
Browse files Browse the repository at this point in the history
  • Loading branch information
tobes committed Dec 12, 2012
1 parent 88e8532 commit a2958bc
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions ckan/new_authz.py
Expand Up @@ -109,6 +109,10 @@ def has_user_permission_for_group_or_org(group_id, user_name, permission):
return False
group_id = model.Group.get(group_id).id

# Sys admins can do anything
if is_sysadmin(user_name):
return True

user_id = get_user_id_for_username(user_name, allow_none=True)
if not user_id:
return False
Expand Down

0 comments on commit a2958bc

Please sign in to comment.