From e426ce257c2285e3c62233a0577b4acb48c5df0b Mon Sep 17 00:00:00 2001 From: Rowan Bohde Date: Wed, 30 Oct 2024 00:12:48 -0500 Subject: [PATCH] remove unused call to $.HeadRepo in view_title template (#32317) This is only populated in [`ParseCompareInfo`](https://github.com/search?q=repo%3Ago-gitea%2Fgitea%20%20.Data%5B%22HeadRepo%22%5D&type=code) which is called in two handlers: * [`CompareAndPullRequestPost`](https://github.com/go-gitea/gitea/blob/9206fbb55fd28f21720072fce6a36cc22277934c/routers/web/repo/pull.go#L1246) - a JSON post handler that doesn't render templates * [`CompareDiff`](https://github.com/go-gitea/gitea/blob/9206fbb55fd28f21720072fce6a36cc22277934c/routers/web/repo/compare.go#L706) - which can render `diff/box.tmpl` and `diff/compare.tmpl` (cherry picked from commit 1cd3f698591edf4fba7880a150b05855cdf40d47) --- templates/repo/issue/view_title.tmpl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/templates/repo/issue/view_title.tmpl b/templates/repo/issue/view_title.tmpl index f63cea1856..13580ebbf9 100644 --- a/templates/repo/issue/view_title.tmpl +++ b/templates/repo/issue/view_title.tmpl @@ -117,7 +117,7 @@ {{$sameBase := ne $.BaseName $.HeadUserName}} {{$differentBranch := ne . $.HeadBranch}} {{if or $sameBase $differentBranch}} -
{{$.BaseName}}{{if $.HeadRepo}}/{{$.HeadRepo}}{{end}}:{{.}}
+
{{$.BaseName}}:{{.}}
{{end}} {{end}}