mirror of
https://github.com/ArchiveBox/ArchiveBox
synced 2024-11-10 14:44:18 +00:00
fix: Return empty QuerySet instead of list
This commit is contained in:
parent
823df34080
commit
fb67d6684c
1 changed files with 1 additions and 1 deletions
|
@ -51,7 +51,7 @@ def query_search_index(query: str, out_dir: Path=OUTPUT_DIR) -> QuerySet:
|
||||||
qsearch = Snapshot.objects.filter(pk__in=snapshot_ids)
|
qsearch = Snapshot.objects.filter(pk__in=snapshot_ids)
|
||||||
return qsearch
|
return qsearch
|
||||||
else:
|
else:
|
||||||
return []
|
return Snapshot.objects.none()
|
||||||
|
|
||||||
@enforce_types
|
@enforce_types
|
||||||
def flush_search_index(snapshots: QuerySet):
|
def flush_search_index(snapshots: QuerySet):
|
||||||
|
|
Loading…
Reference in a new issue