From f100a21cc7e2111152163862e5c83de1ea734e82 Mon Sep 17 00:00:00 2001 From: Andy Han Date: Sat, 30 Dec 2023 16:56:48 +0800 Subject: [PATCH] Fix badge's repoUrl with rootpath (#3076) Fix #3032 again. --- web/src/components/repo/settings/BadgeTab.vue | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/web/src/components/repo/settings/BadgeTab.vue b/web/src/components/repo/settings/BadgeTab.vue index 991ebef09d..8583d5b03e 100644 --- a/web/src/components/repo/settings/BadgeTab.vue +++ b/web/src/components/repo/settings/BadgeTab.vue @@ -90,7 +90,8 @@ const badgeUrl = computed( () => `${rootPath}/api/badges/${repo.value.id}/status.svg${branch.value !== '' ? `?branch=${branch.value}` : ''}`, ); const repoUrl = computed( - () => `/repos/${repo.value.id}${branch.value !== '' ? `/branches/${encodeURIComponent(branch.value)}` : ''}`, + () => + `${rootPath}/repos/${repo.value.id}${branch.value !== '' ? `/branches/${encodeURIComponent(branch.value)}` : ''}`, ); const badgeContent = computed(() => {