From 8da327808654d8da194e92c6c5918cfbf546f032 Mon Sep 17 00:00:00 2001 From: Michael Roytman <mroytman@edx.org> Date: Wed, 15 Aug 2018 12:49:09 -0400 Subject: [PATCH] remove global staff check on enable_checklists_quality waffle flag --- cms/djangoapps/contentstore/config/waffle_utils.py | 5 ++--- cms/templates/checklists.html | 2 +- cms/templates/course_outline.html | 2 +- 3 files changed, 4 insertions(+), 5 deletions(-) diff --git a/cms/djangoapps/contentstore/config/waffle_utils.py b/cms/djangoapps/contentstore/config/waffle_utils.py index eb107198ab1..f1b73abe037 100644 --- a/cms/djangoapps/contentstore/config/waffle_utils.py +++ b/cms/djangoapps/contentstore/config/waffle_utils.py @@ -15,14 +15,13 @@ def should_show_checklists_page(): return False -def should_show_checklists_quality(requesting_user, course_key): +def should_show_checklists_quality(course_key): """ Determine if the ENABLE_CHECKLISTS_QUALITY waffle flag is set and if the user is able to see it """ if ENABLE_CHECKLISTS_QUALITY.is_enabled(course_key): - if GlobalStaff().has_user(requesting_user): - return True + return True return False diff --git a/cms/templates/checklists.html b/cms/templates/checklists.html index a2592dbb263..8951a5c33de 100644 --- a/cms/templates/checklists.html +++ b/cms/templates/checklists.html @@ -52,7 +52,7 @@ "help_tokens": { "files": "${get_online_help_info(online_help_token())['doc_url'] | n, js_escaped_string}" }, - "enable_quality": ${should_show_checklists_quality(request.user, context_course.id) | n, dump_js_escaped_json}, + "enable_quality": ${should_show_checklists_quality(context_course.id) | n, dump_js_escaped_json}, "links": { "certificates": ${reverse('certificates_list_handler', kwargs={'course_key_string': unicode(course_key)})| n, dump_js_escaped_json}, "course_outline": ${reverse('course_handler', kwargs={'course_key_string': unicode(course_key)})| n, dump_js_escaped_json}, diff --git a/cms/templates/course_outline.html b/cms/templates/course_outline.html index b16b8b76515..b7bbe8c4737 100644 --- a/cms/templates/course_outline.html +++ b/cms/templates/course_outline.html @@ -184,7 +184,7 @@ from django.core.urlresolvers import reverse "help_tokens": { "files": "${get_online_help_info(online_help_token())['doc_url'] | n, js_escaped_string}" }, - "enable_quality": ${should_show_checklists_quality(request.user, context_course.id) | n, dump_js_escaped_json}, + "enable_quality": ${should_show_checklists_quality(context_course.id) | n, dump_js_escaped_json}, "links": { "settings": ${reverse('settings_handler', kwargs={'course_key_string': unicode(course_key)})| n, dump_js_escaped_json} } -- GitLab