Skip to content

Commit

Permalink
switch check from admin in remote login
Browse files Browse the repository at this point in the history
  • Loading branch information
jrmerz committed Apr 29, 2020
1 parent f4b6571 commit 7bcfc06
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion ckanext/ecosis/controller/user/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,8 @@ def create_remote_login_response(user):
# orgs = logic.get_action('organization_list_for_user')(context,{"permission": "create_dataset"})

user = logic.get_action('user_show')(context, {'id':user})
is_admin = user.get('sysadmin')

user = {
"loggedIn" : True,
"username": user['name'],
Expand All @@ -87,7 +89,6 @@ def create_remote_login_response(user):
#"organizations": orgs
}

is_admin = isAdmin()
if is_admin:
user['admin'] = True

Expand Down

0 comments on commit 7bcfc06

Please sign in to comment.