From ec0f69550ef6fa1d669c141876864bd14be678aa Mon Sep 17 00:00:00 2001 From: Bryan Wilson Date: Thu, 6 Jul 2023 15:40:24 -0700 Subject: [PATCH] fixup: courselike org name comparision for filter --- openedx/core/djangoapps/appsembler/openedx_api/filters.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/openedx/core/djangoapps/appsembler/openedx_api/filters.py b/openedx/core/djangoapps/appsembler/openedx_api/filters.py index 217e96b88fe1..a9a789279930 100644 --- a/openedx/core/djangoapps/appsembler/openedx_api/filters.py +++ b/openedx/core/djangoapps/appsembler/openedx_api/filters.py @@ -109,7 +109,7 @@ def filter_courselike_sequence_qs(request, queryset): """Filter get_queryset return values that return CourseKey Sequences instead of actual QuerySets.""" allowed_org = request.user.organizations.first() - return filter(lambda key: key.org == allowed_org, queryset) + return [courselike for courselike in queryset if courselike.org == allowed_org] class AppsemblerMultiTenantFilterBackend(filters.DjangoFilterBackend):