mirror of
https://github.com/pacnpal/thrilltrack-explorer.git
synced 2025-12-20 23:51:13 -05:00
Fix fetchItems calls on tab switch
This commit is contained in:
@@ -779,7 +779,9 @@ export const ModerationQueue = forwardRef<ModerationQueueRef>((props, ref) => {
|
|||||||
if (!isMountingRef.current && initialFetchCompleteRef.current) {
|
if (!isMountingRef.current && initialFetchCompleteRef.current) {
|
||||||
debouncedFetchItems(debouncedEntityFilter, debouncedStatusFilter, true, activeTabRef.current);
|
debouncedFetchItems(debouncedEntityFilter, debouncedStatusFilter, true, activeTabRef.current);
|
||||||
}
|
}
|
||||||
}, [debouncedEntityFilter, debouncedStatusFilter, user, fetchItems, debouncedFetchItems]);
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
||||||
|
}, [debouncedEntityFilter, debouncedStatusFilter, user]);
|
||||||
|
// Note: fetchItems and debouncedFetchItems are stable callbacks and should NOT trigger this effect
|
||||||
|
|
||||||
// Polling for auto-refresh (only if realtime is disabled)
|
// Polling for auto-refresh (only if realtime is disabled)
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
|
|||||||
Reference in New Issue
Block a user