From 75874687fb4ef970d9e82fa8fbf13aafa0b29bf8 Mon Sep 17 00:00:00 2001 From: rcourtman Date: Sat, 13 Dec 2025 11:05:08 +0000 Subject: [PATCH] chore: Fix all remaining lint warnings - Prefix unused catch error variables with underscore in AIChat.tsx and Alerts.tsx - Reduced lint warnings from 8 to 0 - Clean lint output with no warnings or errors --- frontend-modern/src/components/AI/AIChat.tsx | 2 +- frontend-modern/src/pages/Alerts.tsx | 14 +++++++------- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/frontend-modern/src/components/AI/AIChat.tsx b/frontend-modern/src/components/AI/AIChat.tsx index 28b87f1..8632781 100644 --- a/frontend-modern/src/components/AI/AIChat.tsx +++ b/frontend-modern/src/components/AI/AIChat.tsx @@ -342,7 +342,7 @@ export const AIChat: Component = (props) => { description: m.description, }))); } - } catch (e) { + } catch (_e) { // Silently fail - models will just not be selectable } }); diff --git a/frontend-modern/src/pages/Alerts.tsx b/frontend-modern/src/pages/Alerts.tsx index 72e99f4..111c00b 100644 --- a/frontend-modern/src/pages/Alerts.tsx +++ b/frontend-modern/src/pages/Alerts.tsx @@ -2179,7 +2179,7 @@ function OverviewTab(props: { if (runHistory && runHistory.length > 0 && runHistory[0].status !== 'healthy') { setShowRunHistory(true); } - } catch (e) { + } catch (_e) { // AI patrol may not be enabled - silently fail } }; @@ -2678,7 +2678,7 @@ function OverviewTab(props: { await dismissFinding(finding.id, 'not_an_issue'); showSuccess('Dismissed - AI will not raise this again'); fetchAiData(); - } catch (err) { + } catch (_err) { showError('Failed to dismiss finding'); } }} @@ -2695,7 +2695,7 @@ function OverviewTab(props: { await dismissFinding(finding.id, 'expected_behavior', note || undefined); showSuccess('Dismissed - AI will not raise this again'); fetchAiData(); - } catch (err) { + } catch (_err) { showError('Failed to dismiss finding'); } }} @@ -2711,7 +2711,7 @@ function OverviewTab(props: { await dismissFinding(finding.id, 'will_fix_later'); showSuccess('Acknowledged - AI will check again later'); fetchAiData(); - } catch (err) { + } catch (_err) { showError('Failed to dismiss finding'); } }} @@ -2729,7 +2729,7 @@ function OverviewTab(props: { await suppressFinding(finding.id); showSuccess('Suppressed - AI will never raise this again'); fetchAiData(); - } catch (err) { + } catch (_err) { showError('Failed to suppress finding'); } } @@ -2831,7 +2831,7 @@ function OverviewTab(props: { setNewRuleCategory(''); setNewRuleDescription(''); fetchAiData(); - } catch (err) { + } catch (_err) { showError('Failed to create rule'); } }} @@ -2889,7 +2889,7 @@ function OverviewTab(props: { await deleteSuppressionRule(rule.id); showSuccess('Rule deleted'); fetchAiData(); - } catch (err) { + } catch (_err) { showError('Failed to delete rule'); } }}