mirror of
https://github.com/blakeblackshear/frigate.git
synced 2026-02-12 22:25:24 +03:00
fix events accidently pulling inside chroma results loop
This commit is contained in:
parent
602a49ee3d
commit
9bc6ae4771
@ -399,17 +399,16 @@ def events_search():
|
|||||||
else "description",
|
else "description",
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if not results:
|
||||||
|
return jsonify([])
|
||||||
|
|
||||||
# Get the event data
|
# Get the event data
|
||||||
events = (
|
events = (
|
||||||
Event.select(*selected_columns)
|
Event.select(*selected_columns)
|
||||||
.join(
|
.join(
|
||||||
ReviewSegment,
|
ReviewSegment,
|
||||||
JOIN.LEFT_OUTER,
|
JOIN.LEFT_OUTER,
|
||||||
on=(
|
on=(fn.json_extract(ReviewSegment.data, "$.detections").contains(Event.id)),
|
||||||
fn.json_extract(ReviewSegment.data, "$.detections").contains(
|
|
||||||
Event.id
|
|
||||||
)
|
|
||||||
),
|
|
||||||
)
|
)
|
||||||
.where(Event.id << list(results.keys()))
|
.where(Event.id << list(results.keys()))
|
||||||
.dicts()
|
.dicts()
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user