Skip to content

Commit

Permalink
fix: only test course content metadata (#682)
Browse files Browse the repository at this point in the history
  • Loading branch information
johnnagro authored Sep 29, 2023
1 parent 8e727fe commit 9b3c882
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
from django.core.management.base import BaseCommand

from enterprise_catalog.apps.catalog import filters
from enterprise_catalog.apps.catalog.constants import COURSE
from enterprise_catalog.apps.catalog.models import (
ContentMetadata,
EnterpriseCatalog,
Expand All @@ -22,7 +23,7 @@ def handle(self, *args, **options):
Cook it.
"""
logger.info('compare_catalog_queries_to_filters starting...')
for content_metadata in ContentMetadata.objects.all():
for content_metadata in ContentMetadata.objects.filter(content_type=COURSE):
for enterprise_catalog in EnterpriseCatalog.objects.all():
discovery_included = content_metadata in enterprise_catalog.content_metadata
match = filters.does_query_match_content(
Expand Down

0 comments on commit 9b3c882

Please sign in to comment.