1
1
mirror of https://github.com/go-gitea/gitea synced 2025-07-26 12:18:36 +00:00

Clean template/helper.go (#23922)

The first step of #23328

This PR cleans:

1. Dead function like `SubStr`
2. Unnecessary function like `UseHTTPS`, it should be provided by
`window.origin`
3. Duplicate function like `IsShowFullName`, there was already a
`DeafultShowFullName`

I have searched these removed functions globally, no use in code.
This commit is contained in:
wxiaoguang
2023-04-07 15:31:41 +08:00
committed by GitHub
parent 17623bba0d
commit ff2f479a4b
6 changed files with 11 additions and 77 deletions

View File

@@ -1,7 +1,7 @@
<!-- there is always at least one button (by context/repo.go) -->
{{if $.CloneButtonShowHTTPS}}
<button class="ui basic small compact clone button gt-no-transition" id="repo-clone-https" data-link="{{$.CloneButtonOriginLink.HTTPS}}">
{{if UseHTTPS}}HTTPS{{else}}HTTP{{end}}
HTTPS
</button>
{{end}}
{{if $.CloneButtonShowSSH}}