Skip to content

Commit

Permalink
fix(endpoint/log.html): fix escaping issue on next/prev link
Browse files Browse the repository at this point in the history
  • Loading branch information
macrat committed Dec 13, 2022
1 parent 975e196 commit 335a489
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions internal/endpoint/templates/log.html
Original file line number Diff line number Diff line change
Expand Up @@ -89,13 +89,13 @@
{{ define "pager" }}
<div class="pager">
{{- if gt .From 1 }}
<a href="/log.html?{{ .RawQuery }}&limit={{ .Limit }}&offset={{ .Prev }}" class="pager-link" title="Previous page">&lt;</a>
<a href="{{ printf "/log.html?%s&limit=%d&offset=%d" .RawQuery .Limit .Prev }}" class="pager-link" title="Previous page">&lt;</a>
{{ else }}
<a class="pager-link disabled" aria-label="There is not previous page.">&lt;</a>
{{ end -}}
<span aria-label="Showing record {{ .From }} to {{ .To }} out of {{ .Total }}.">{{ .From | uint2humanize }}-{{ .To | uint2humanize }} of {{ .Total | uint2humanize }}</span>
{{- if lt .To .Total }}
<a href="/log.html?{{ .RawQuery }}&limit={{ .Limit }}&offset={{ .Next }}" class="pager-link" title="Next page">&gt;</a>
<a href="{{ printf "/log.html?%s&limit=%d&offset=%d" .RawQuery .Limit .Next }}" class="pager-link" title="Next page">&gt;</a>
{{ else }}
<a class="pager-link disabled" aria-label="There is no next page.">&gt;</a>
{{ end }}
Expand Down

0 comments on commit 335a489

Please sign in to comment.