mirror of https://gitea.com/gitea/theme.git
chore: check for https:// prefix
Signed-off-by: jolheiser <john.olheiser@gmail.com>
This commit is contained in:
parent
7c33619e3f
commit
15406ce8ac
|
@ -15,12 +15,12 @@
|
|||
{{ $s.Set "len" (len .Params.authors) }}
|
||||
{{ $s.Add "len" -1 }}
|
||||
{{ range $idx, $author := .Params.authors -}}
|
||||
<a class="author" href="{{ if hasPrefix $author "http" }}{{ $author }}{{ else }}https://gitea.com/{{ $author }}{{ end }}">
|
||||
<a class="author" href="{{ if hasPrefix $author "https://" }}{{ $author }}{{ else }}https://gitea.com/{{ $author }}{{ end }}">
|
||||
{{ path.BaseName $author }}
|
||||
</a>{{ if ne $idx ($s.Get "len") }}, {{end}}
|
||||
{{- end }}
|
||||
{{ else }}
|
||||
<a class="author" href="{{ if hasPrefix .Params.author "http" }}{{ .Params.author }}{{ else }}https://gitea.com/{{ .Params.author }}{{ end }}">
|
||||
<a class="author" href="{{ if hasPrefix .Params.author "https://" }}{{ .Params.author }}{{ else }}https://gitea.com/{{ .Params.author }}{{ end }}">
|
||||
{{ path.BaseName (.Params.author | default .Site.Params.author) }}
|
||||
</a>
|
||||
{{ end }}
|
||||
|
|
|
@ -18,12 +18,12 @@
|
|||
{{ $s.Set "len" (len .Params.authors) }}
|
||||
{{ $s.Add "len" -1 }}
|
||||
{{ range $idx, $author := .Params.authors -}}
|
||||
<a class="author" href="{{ if hasPrefix $author "http" }}{{ $author }}{{ else }}https://gitea.com/{{ $author }}{{ end }}">
|
||||
<a class="author" href="{{ if hasPrefix $author "https://" }}{{ $author }}{{ else }}https://gitea.com/{{ $author }}{{ end }}">
|
||||
{{ path.BaseName $author }}
|
||||
</a>{{ if ne $idx ($s.Get "len") }}, {{end}}
|
||||
{{- end }}
|
||||
{{ else }}
|
||||
<a class="author" href="{{ if hasPrefix .Params.author "http" }}{{ .Params.author }}{{ else }}https://gitea.com/{{ .Params.author }}{{ end }}">
|
||||
<a class="author" href="{{ if hasPrefix .Params.author "https://" }}{{ .Params.author }}{{ else }}https://gitea.com/{{ .Params.author }}{{ end }}">
|
||||
{{ path.BaseName (.Params.author | default .Site.Params.author) }}
|
||||
</a>
|
||||
{{ end }}
|
||||
|
|
Loading…
Reference in New Issue