From 338f1b119cea35872a56d060399b0d090a805aed Mon Sep 17 00:00:00 2001 From: Tyler Kennedy Date: Fri, 27 Jan 2017 15:27:52 -0500 Subject: [PATCH] Always call check_access, even if a user does not exist. --- ckan/logic/action/get.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ckan/logic/action/get.py b/ckan/logic/action/get.py index cf4f832310d..62905e1e5dc 100644 --- a/ckan/logic/action/get.py +++ b/ckan/logic/action/get.py @@ -1493,6 +1493,8 @@ def user_show(context, data_dict): :rtype: dictionary ''' + _check_access('user_show', context, data_dict) + model = context['model'] id = data_dict.get('id', None) @@ -1507,8 +1509,6 @@ def user_show(context, data_dict): else: raise NotFound - _check_access('user_show', context, data_dict) - # include private and draft datasets? requester = context.get('user') sysadmin = False