aboutsummaryrefslogtreecommitdiffstats
path: root/templates/repo
diff options
context:
space:
mode:
authorGiteabot <teabot@gitea.io>2023-12-22 10:29:28 +0800
committerGitHub <noreply@github.com>2023-12-22 02:29:28 +0000
commitacc8100d47bab3b13311bcf4c330b19e2153d4ca (patch)
treeb5301f15905cfdf0d97b09ae7078594262018eb9 /templates/repo
parent1a3803effd42df628090b436b44a902482413e45 (diff)
downloadgitea-acc8100d47bab3b13311bcf4c330b19e2153d4ca.tar.gz
gitea-acc8100d47bab3b13311bcf4c330b19e2153d4ca.zip
Fix 500 error of searching commits (#28576) (#28579)
Backport #28576 by wxiaoguang Regression of #28454 . Now the string is escaped HTML, so it doesn't need `| Safe`. Fix #28575 Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
Diffstat (limited to 'templates/repo')
-rw-r--r--templates/repo/search.tmpl2
1 files changed, 1 insertions, 1 deletions
diff --git a/templates/repo/search.tmpl b/templates/repo/search.tmpl
index b6c90de32f..b616b4de32 100644
--- a/templates/repo/search.tmpl
+++ b/templates/repo/search.tmpl
@@ -53,7 +53,7 @@
<a href="{{$.SourcePath}}/src/commit/{{PathEscape $result.CommitID}}/{{PathEscapeSegments $result.Filename}}#L{{.}}"><span>{{.}}</span></a>
{{end}}
</td>
- <td class="lines-code chroma"><code class="code-inner">{{.FormattedLines | Safe}}</code></td>
+ <td class="lines-code chroma"><code class="code-inner">{{.FormattedLines}}</code></td>
</tr>
</tbody>
</table>