Skip to content

Commit

Permalink
👌 update depreciated code
Browse files Browse the repository at this point in the history
change depreciated .URL to .RelPermalink thx @VincentTam
  • Loading branch information
pad92 committed May 3, 2019
1 parent 1f074b4 commit 8b4cb54
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions layouts/_default/section.html
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ <h2 class="archive-year">{{ $thisYear }}</h2>
{{ $element.Date.Format "01-02" }}
</span>
<span class="archive-post-title">
<a href="{{ $element.URL }}" class="archive-post-link">
<a href="{{ $element.RelPermalink }}" class="archive-post-link">
{{ .Title }}
</a>
</span>
Expand All @@ -46,12 +46,12 @@ <h2 class="archive-year">{{ $thisYear }}</h2>
<ul class="pager main-pager">
{{ if .Paginator.HasPrev }}
<li class="previous">
<a href="{{ .URL }}page/{{ .Paginator.Prev.PageNumber }}/">&larr; {{ i18n "newerPosts" }}</a>
<a href="{{ .RelPermalink }}page/{{ .Paginator.Prev.PageNumber }}/">&larr; {{ i18n "newerPosts" }}</a>
</li>
{{ end }}
{{ if .Paginator.HasNext }}
<li class="next">
<a href="{{ .URL }}page/{{ .Paginator.Next.PageNumber }}/">{{ i18n "olderPosts" }} &rarr;</a>
<a href="{{ .RelPermalink }}page/{{ .Paginator.Next.PageNumber }}/">{{ i18n "olderPosts" }} &rarr;</a>
</li>
{{ end }}
</ul>
Expand Down

0 comments on commit 8b4cb54

Please sign in to comment.