Skip to content

Commit

Permalink
Remove unnecessary Safe tags (#3779)
Browse files Browse the repository at this point in the history
  • Loading branch information
Bwko authored and lafriks committed Apr 11, 2018
1 parent 31c0a33 commit af7779d
Show file tree
Hide file tree
Showing 6 changed files with 13 additions and 14 deletions.
6 changes: 3 additions & 3 deletions templates/repo/branch/list.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -69,12 +69,12 @@
<div class="ui small basic delete modal">
<div class="ui icon header">
<i class="trash icon"></i>
{{.i18n.Tr "repo.branch.delete_html"| Safe}} <span class="branch-name"></span>
{{.i18n.Tr "repo.branch.delete_html"}} <span class="branch-name"></span>
</div>
<div class="content">
<p>{{.i18n.Tr "repo.branch.delete_desc" | Safe}}</p>
<p>{{.i18n.Tr "repo.branch.delete_desc"}}</p>
{{.i18n.Tr "repo.branch.delete_notices_1" | Safe}}<br>
{{.i18n.Tr "repo.branch.delete_notices_html" | Safe}} <span class="branch-name"></span><br>
{{.i18n.Tr "repo.branch.delete_notices_html"}} <span class="branch-name"></span><br>
</div>
{{template "base/delete_modal_actions" .}}
</div>
Expand Down
2 changes: 1 addition & 1 deletion templates/repo/create.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@
<div class="inline required field {{if .Err_RepoName}}error{{end}}">
<label for="repo_name">{{.i18n.Tr "repo.repo_name"}}</label>
<input id="repo_name" name="repo_name" value="{{.repo_name}}" autofocus required>
<span class="help">{{.i18n.Tr "repo.repo_name_helper" | Safe}}</span>
<span class="help">{{.i18n.Tr "repo.repo_name_helper"}}</span>
</div>
<div class="inline field">
<label>{{.i18n.Tr "repo.visibility"}}</label>
Expand Down
3 changes: 1 addition & 2 deletions templates/repo/editor/commit_form.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,7 @@
<input type="radio" class="js-quick-pull-choice-option" name="commit_choice" value="direct" {{if eq .commit_choice "direct"}}checked{{end}}>
<label>
<i class="octicon octicon-git-commit" height="16" width="14"></i>
{{$branchName := .BranchName | Str2html}}
{{.i18n.Tr "repo.editor.commit_directly_to_this_branch" $branchName | Safe}}
{{.i18n.Tr "repo.editor.commit_directly_to_this_branch" (.BranchName|Escape) | Safe}}
</label>
</div>
</div>
Expand Down
6 changes: 3 additions & 3 deletions templates/repo/issue/view_content.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -134,12 +134,12 @@
<div class="ui small basic delete modal">
<div class="ui icon header">
<i class="trash icon"></i>
{{.i18n.Tr "repo.branch.delete" .HeadTarget | Safe}}
{{.i18n.Tr "repo.branch.delete" .HeadTarget }}
</div>
<div class="content">
<p>{{.i18n.Tr "repo.branch.delete_desc" | Safe}}</p>
<p>{{.i18n.Tr "repo.branch.delete_desc"}}</p>
{{.i18n.Tr "repo.branch.delete_notices_1" | Safe}}<br>
{{.i18n.Tr "repo.branch.delete_notices_2" .HeadTarget | Safe}}<br>
{{.i18n.Tr "repo.branch.delete_notices_2" .HeadTarget}}<br>
</div>
{{template "base/delete_modal_actions" .}}
</div>
2 changes: 1 addition & 1 deletion templates/repo/issue/view_content/comments.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,7 @@
<img src="{{.Poster.RelAvatarLink}}">
</a>
<span class="text grey"><a href="{{.Poster.HomeLink}}">{{.Poster.Name}}</a>
{{$.i18n.Tr "repo.issues.delete_branch_at" .CommitSHA $createdStr | Safe}}
{{$.i18n.Tr "repo.issues.delete_branch_at" (.CommitSHA|Escape) $createdStr | Safe}}
</span>
</div>
{{else if eq .Type 12}}
Expand Down
8 changes: 4 additions & 4 deletions templates/repo/settings/options.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -302,7 +302,7 @@
</div>
<div class="content">
<div class="ui warning message text left">
{{.i18n.Tr "repo.settings.convert_notices_1" | Safe}}
{{.i18n.Tr "repo.settings.convert_notices_1"}}
</div>
<form class="ui form" action="{{.Link}}" method="post">
{{.CsrfTokenHtml}}
Expand Down Expand Up @@ -333,8 +333,8 @@
</div>
<div class="content">
<div class="ui warning message text left">
{{.i18n.Tr "repo.settings.transfer_notices_1" | Safe}} <br>
{{.i18n.Tr "repo.settings.transfer_notices_2" | Safe}}
{{.i18n.Tr "repo.settings.transfer_notices_1"}} <br>
{{.i18n.Tr "repo.settings.transfer_notices_2"}}
</div>
<form class="ui form" action="{{.Link}}" method="post">
{{.CsrfTokenHtml}}
Expand Down Expand Up @@ -371,7 +371,7 @@
{{.i18n.Tr "repo.settings.delete_notices_1" | Safe}}<br>
{{.i18n.Tr "repo.settings.delete_notices_2" .Repository.FullName | Safe}}
{{if .Repository.NumForks}}<br>
{{.i18n.Tr "repo.settings.delete_notices_fork_1" | Safe}}
{{.i18n.Tr "repo.settings.delete_notices_fork_1"}}
{{end}}
</div>
<form class="ui form" action="{{.Link}}" method="post">
Expand Down

0 comments on commit af7779d

Please sign in to comment.