mirror of
https://codeberg.org/forgejo/forgejo.git
synced 2025-05-25 11:22:16 +00:00
Rename Str2html to SanitizeHTML and clarify its behavior (#29516)
Str2html was abused a lot. So use a proper name for it: SanitizeHTML And add some tests to show its behavior. (cherry picked from commit fb42972c057364a1dc99dfb528554e7a94415be7) Conflicts: docs/content/administration/mail-templates.en-us.md docs/content/administration/mail-templates.zh-cn.md prefer their version always
This commit is contained in:
parent
58bc3af08d
commit
2892aaab02
14 changed files with 52 additions and 47 deletions
|
@ -276,7 +276,7 @@
|
|||
<span class="text grey" id="note-authored-time">{{TimeSince .NoteCommit.Author.When ctx.Locale}}</span>
|
||||
</div>
|
||||
<div class="ui bottom attached info segment git-notes">
|
||||
<pre class="commit-body">{{.NoteRendered | Str2html}}</pre>
|
||||
<pre class="commit-body">{{.NoteRendered | SanitizeHTML}}</pre>
|
||||
</div>
|
||||
{{end}}
|
||||
{{template "repo/diff/box" .}}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue