loading up the forgejo repo on tangled to test page performance
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

Fix template bugs in recently_pushed_new_branches.tmpl (#26744)

Fix some bugs from #25715, fix #25830

1. `$.locale.Tr ... Safe` needs `Escape`, but not `PathEscapeSegments`
2. The attribute should be `role`
3. The `ComposeBranchCompareURL` already does escaping correctly

authored by

wxiaoguang and committed by
GitHub
5914a2f8 4fdb09de

+2 -2
+2 -2
templates/repo/code/recently_pushed_new_branches.tmpl
··· 2 2 <div class="ui positive message gt-df gt-ac"> 3 3 <div class="gt-f1"> 4 4 {{$timeSince := TimeSince .CommitTime.AsTime $.locale}} 5 - {{$.locale.Tr "repo.pulls.recently_pushed_new_branches" (PathEscapeSegments .Name) $timeSince | Safe}} 5 + {{$.locale.Tr "repo.pulls.recently_pushed_new_branches" (Escape .Name) $timeSince | Safe}} 6 6 </div> 7 - <a aria-role="button" class="ui compact positive button gt-m-0" href="{{$.Repository.ComposeBranchCompareURL $.Repository.BaseRepo (PathEscapeSegments .Name)}}"> 7 + <a role="button" class="ui compact positive button gt-m-0" href="{{$.Repository.ComposeBranchCompareURL $.Repository.BaseRepo .Name}}"> 8 8 {{$.locale.Tr "repo.pulls.compare_changes"}} 9 9 </a> 10 10 </div>