fix(dashboard): the Managed Git hint links one docs path in both languages (#980) (#991)
CI / Check (push) Skipped
CI / Agent integration (push) Skipped
CI / Detect Changes (push) Successful in 3s
CI / Deploy Agent (push) Skipped
CI / Deploy Docs (push) Skipped
CI / Deploy MCP (push) Skipped
CI / Deploy Dashboard (push) Successful in 3m56s
CI / Check (push) Skipped
CI / Agent integration (push) Skipped
CI / Detect Changes (push) Successful in 3s
CI / Deploy Agent (push) Skipped
CI / Deploy Docs (push) Skipped
CI / Deploy MCP (push) Skipped
CI / Deploy Dashboard (push) Successful in 3m56s
On prod, DOCS_URL is the customer docs site, which keeps a page at the same path under each language root and has no "-en" pages: the English link to guide/managed-git-en would 404 there. Both languages now link guide/managed-git. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit was merged in pull request #991.
This commit is contained in:
1 parent
ea1b48dd37
commit
783e075891
1 file changed
+6
-9
@@ -158,13 +158,10 @@ pub fn FindingDetailPage(id: String) -> Element {
|
||||
&me.docs_url,
|
||||
"guide/repositories#connecting-an-issue-tracker",
|
||||
);
|
||||
let managed_git_guide = docs_page(
|
||||
&me.docs_url,
|
||||
match lang {
|
||||
Lang::De => "guide/managed-git",
|
||||
Lang::En => "guide/managed-git-en",
|
||||
},
|
||||
);
|
||||
// The same path in both languages: the customer docs site
|
||||
// (prod's `DOCS_URL`) keeps each page at one path per language
|
||||
// root and has no `-en` pages.
|
||||
let managed_git_guide = docs_page(&me.docs_url, "guide/managed-git");
|
||||
// `move` closures take ownership (like a Python closure capturing
|
||||
// by value), so the copy handler gets its own clones.
|
||||
let finding_for_copy = f.clone();
|
||||
@@ -915,8 +912,8 @@ mod tests {
|
||||
"/docs/guide/managed-git"
|
||||
);
|
||||
assert_eq!(
|
||||
docs_page("https://docs.example/pruefwerk", "guide/managed-git-en"),
|
||||
"https://docs.example/pruefwerk/guide/managed-git-en"
|
||||
docs_page("https://docs.example/pruefwerk/", "guide/managed-git"),
|
||||
"https://docs.example/pruefwerk/guide/managed-git"
|
||||
);
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user