diff --git a/routes/_middleware.ts b/routes/_middleware.ts index 9586fae..5bbf20d 100644 --- a/routes/_middleware.ts +++ b/routes/_middleware.ts @@ -58,7 +58,11 @@ function ga4( } else { exceptionEvent = null; } - if (conn.url.pathname === "/healthz") { + const userAgents: Array = ['textlint-rule-no-dead-link/1.0'] + if(userAgents.includes(request.headers.get("user-agent"))) { + return + } + if (conn.url.pathname === "/healthz"){ return; }