mirror of
https://github.com/blakeblackshear/frigate.git
synced 2026-02-01 16:55:21 +03:00
moved delete reducer
This commit is contained in:
parent
0eefea6d0b
commit
8925059944
@ -82,13 +82,17 @@ export default function Events({ path: pathname, limit = API_LIMIT } = {}) {
|
||||
if (data && Array.isArray(data) && data.length + deleted < limit) {
|
||||
dispatch({ type: 'REACHED_END', meta: { searchString } });
|
||||
}
|
||||
}, [data, limit, searchString, searchStrings, deleted]);
|
||||
|
||||
useEffect(() => {
|
||||
if (deletedId) {
|
||||
dispatch({ type: 'DELETE_EVENT', deletedId });
|
||||
}
|
||||
}, [deletedId]);
|
||||
}, [data, limit, searchString, searchStrings, deleted, deletedId]);
|
||||
|
||||
// useEffect(() => {
|
||||
// if (deletedId) {
|
||||
// dispatch({ type: 'DELETE_EVENT', deletedId });
|
||||
// }
|
||||
// }, [deletedId]);
|
||||
|
||||
const [entry, setIntersectNode] = useIntersectionObserver();
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user