fix: use case-insensitive matching for prometheus agent detection in prometheus-md-only hook

The hook used exact string equality (agentName !== "prometheus") which fails
when display names like "Prometheus (Plan Builder)" are stored in session state.
Replace with case-insensitive substring matching via isPrometheusAgent() helper,
consistent with the pattern used in keyword-detector hook.

Closes #1764 (Bug 3)
This commit is contained in:
YeonGyu-Kim
2026-02-12 03:36:58 +09:00
parent 69494d7e5b
commit 454acf757c
3 changed files with 126 additions and 4 deletions
@@ -0,0 +1,5 @@
import { PROMETHEUS_AGENT } from "./constants"
export function isPrometheusAgent(agentName: string | undefined): boolean {
return agentName?.toLowerCase().includes(PROMETHEUS_AGENT) ?? false
}