Add more comments about source parsing
This commit is contained in:
@@ -542,6 +542,10 @@ class ElasticsearchBackend(StorageBackend):
|
||||
total_sources = (
|
||||
len(settings.MAIN_SOURCES) - 1 + len(settings.SOURCES_RESTRICTED)
|
||||
)
|
||||
|
||||
# If the sources the user has access to are equal to all
|
||||
# possible sources, then we don't need to add the source
|
||||
# filter to the query.
|
||||
if total_count != total_sources:
|
||||
add_top_tmp = {"bool": {"should": []}}
|
||||
for source_iter in sources:
|
||||
|
||||
Reference in New Issue
Block a user