Skip to content

Commit

Permalink
feat: remove staff access for catalog views
Browse files Browse the repository at this point in the history
  • Loading branch information
andrey-canon committed Nov 19, 2024
1 parent 5071f28 commit 0663883
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion lms/djangoapps/courseware/access.py
Original file line number Diff line number Diff line change
Expand Up @@ -394,7 +394,10 @@ def can_see_in_catalog():
"""
return (
_has_catalog_visibility(courselike, CATALOG_VISIBILITY_CATALOG_AND_ABOUT)
or _has_staff_access_to_block(user, courselike, courselike.id)
or (
_has_staff_access_to_block(user, courselike, courselike.id)
and getattr(settings, "STAFF_CAN_SEE_IN_CATALOG", True)
)
)

@function_trace('can_see_about_page')
Expand Down

0 comments on commit 0663883

Please sign in to comment.