-
Notifications
You must be signed in to change notification settings - Fork 171
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: exclude retired coursetypes and runtypes from api #4525
Conversation
if self.request.method == "GET" and HIDE_RETIRED_COURSE_AND_COURSE_RUNS.is_enabled() and not get_query_param(self.request, 'include_retired'): | ||
retired_type_ids = list(map(lambda ct: ct.id, CourseRunType.objects.filter(slug__in=settings.RETIRED_RUN_TYPES))) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
include_retired is semantically confusing. Is it referencing retired product, archived product, or something else? We can be explicit here, include_retired_course_types or include_retired_product_type, etc.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
please squash the commits and add PR description before merge.
8ea0d8e
to
78f8d26
Compare
PROD-4259
Exclude courses and courseruns belonging to retired types in API responses.