From b1764267dc05bd37eaf314133f06764c0b630c60 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Fri, 10 Apr 2026 19:00:43 +0000 Subject: [PATCH] fix: strip trailing slash from BASE_URL to prevent double slashes in URLs Agent-Logs-Url: https://github.com/samber/awesome-prometheus-alerts/sessions/c85937ba-1855-4b8a-a72b-847eab1c8639 Co-authored-by: samber <2951285+samber@users.noreply.github.com> --- site/src/components/SearchWidget.astro | 4 ++-- site/src/layouts/BaseLayout.astro | 2 +- site/src/layouts/GuideLayout.astro | 2 +- site/src/pages/alertmanager.astro | 2 +- site/src/pages/blackbox-exporter.astro | 2 +- site/src/pages/index.astro | 2 +- site/src/pages/rules/[group]/[service].astro | 2 +- site/src/pages/rules/[group]/index.astro | 2 +- site/src/pages/rules/index.astro | 2 +- 9 files changed, 10 insertions(+), 10 deletions(-) diff --git a/site/src/components/SearchWidget.astro b/site/src/components/SearchWidget.astro index 57dc0f8..58dbdbe 100644 --- a/site/src/components/SearchWidget.astro +++ b/site/src/components/SearchWidget.astro @@ -5,7 +5,7 @@ interface Props { class?: string; } const { class: extraClass = '' } = Astro.props; -const base = import.meta.env.BASE_URL; +const base = import.meta.env.BASE_URL.replace(/\/$/, ''); --- @@ -14,7 +14,7 @@ const base = import.meta.env.BASE_URL;