diff --git a/desktop/plugins/public/logs/index.tsx b/desktop/plugins/public/logs/index.tsx index ccea40ca4..bd7b62c98 100644 --- a/desktop/plugins/public/logs/index.tsx +++ b/desktop/plugins/public/logs/index.tsx @@ -184,7 +184,9 @@ export function devicePlugin(client: DevicePluginClient) { } async function clearLogs() { - await client.device.clearLogs(); + if (client.device.connected.get()) { + await client.device.clearLogs(); + } rows.clear(); tableManagerRef.current?.clearSelection(); }