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:
@@ -0,0 +1,5 @@
|
||||
import { PROMETHEUS_AGENT } from "./constants"
|
||||
|
||||
export function isPrometheusAgent(agentName: string | undefined): boolean {
|
||||
return agentName?.toLowerCase().includes(PROMETHEUS_AGENT) ?? false
|
||||
}
|
||||
Reference in New Issue
Block a user