Skip to content

Self-hosted homelab infrastructure visualizer — interactive network diagram with live status monitoring

fix(pending): drop dangling onNodeApproved call + add keydown deps

Pouzorb17299f53115
diff --git a/frontend/src/components/modals/PendingDevicesModal.tsx b/frontend/src/components/modals/PendingDevicesModal.tsx
index 8f03be6..c9fa61f 100644
--- a/frontend/src/components/modals/PendingDevicesModal.tsx
+++ b/frontend/src/components/modals/PendingDevicesModal.tsx
@@ -258,7 +258,6 @@ export function PendingDevicesModal({ open, onClose, highlightId, initialStatus
toast.success(`Approved ${nodeData.label}${extra}`)
setDevices((prev) => prev.filter((d) => d.id !== device.id))
setSelected(null)
- onNodeApproved(nodeId)
} catch {
toast.error('Failed to approve device')
}
@@ -352,7 +351,8 @@ export function PendingDevicesModal({ open, onClose, highlightId, initialStatus
}
window.addEventListener('keydown', handler)
return () => window.removeEventListener('keydown', handler)
- })
+ // eslint-disable-next-line react-hooks/exhaustive-deps
+ }, [open, selectMode, selectedIds, filtered])
return (
<>