Skip to content

Commit

Permalink
fixup: courselike org name comparision for filter
Browse files Browse the repository at this point in the history
  • Loading branch information
bryanlandia committed Jul 6, 2023
1 parent 97d7299 commit ec0f695
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion openedx/core/djangoapps/appsembler/openedx_api/filters.py
Original file line number Diff line number Diff line change
Expand Up @@ -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):
Expand Down

0 comments on commit ec0f695

Please sign in to comment.