Skip to content

Commit

Permalink
fix: settings name overshadow
Browse files Browse the repository at this point in the history
  • Loading branch information
DanielVZ96 committed Nov 28, 2024
1 parent 73957b6 commit 084c2f6
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions openedx/core/djangoapps/content/search/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -397,15 +397,15 @@ def _is_index_configured(index_name: str) -> bool:
"""
client = _get_meilisearch_client()
index = client.get_index(index_name)
settings = index.get_settings()
index_settings = index.get_settings()
for k, v in (
("distinctAttribute", INDEX_DISTINCT_ATTRIBUTE),
("filterableAttributes", INDEX_FILTRABLE_ATTRIBUTES),
("searchableAttributes", INDEX_SEARCHABLE_ATTRIBUTES),
("sortableAttributes", INDEX_SORTABLE_ATTRIBUTES),
("rankingRules", INDEX_RANKING_RULES),
):
setting = settings.get(k, [])
setting = index_settings.get(k, [])
if isinstance(v, list):
v = set(v)
setting = set(setting)
Expand Down

0 comments on commit 084c2f6

Please sign in to comment.