Live preview gifs should be updated on refocus (#10007)

This commit is contained in:
Nicolas Mowen 2024-02-24 06:50:33 -07:00 committed by GitHub
parent 824e5ec3a3
commit c7e9fe7234
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -14,10 +14,10 @@ function Live() {
// recent events // recent events
const { payload: eventUpdate } = useFrigateEvents(); const { payload: eventUpdate } = useFrigateEvents();
const { data: allEvents, mutate: updateEvents } = useSWR<FrigateEvent[]>( const { data: allEvents, mutate: updateEvents } = useSWR<FrigateEvent[]>([
["events", { limit: 10 }], "events",
{ revalidateOnFocus: false } { limit: 10 },
); ]);
useEffect(() => { useEffect(() => {
if (!eventUpdate) { if (!eventUpdate) {