shithub: hugo

Download patch

ref: b0b6a8c7acf85a7b08ead56df81caeeea0ffff3b
parent: d7ef272a23ba937544beaa66a60bc7043bd566f7
author: Gustav Näslund <[email protected]>
date: Mon Nov 30 15:52:30 EST 2015

Use .Site.Pages in the documentation examples instead of .Site.Recent

--- a/docs/content/templates/functions.md
+++ b/docs/content/templates/functions.md
@@ -161,7 +161,7 @@
     <ul>
     {{ $page_link := .Permalink }}
     {{ $tags := .Params.tags }}
-    {{ range .Site.Recent }}
+    {{ range .Site.Pages }}
         {{ $page := . }}
         {{ $has_common_tags := intersect $tags .Params.tags | len | lt 0 }}
         {{ if and $has_common_tags (ne $page_link $page.Permalink) }}
@@ -259,7 +259,7 @@
     series: golang
     +++
 
-    {{ range where .Site.Recent "Params.series" "golang" }}
+    {{ range where .Site.Pages "Params.series" "golang" }}
        {{ .Content }}
     {{ end }}
 
--- a/docs/content/templates/go-templates.md
+++ b/docs/content/templates/go-templates.md
@@ -382,7 +382,7 @@
 ```
 <nav class="recent">
   <h1>Recent Posts</h1>
-  <ul>{{range first .Site.Params.SidebarRecentLimit .Site.Recent}}
+  <ul>{{range first .Site.Params.SidebarRecentLimit .Site.Pages}}
     <li><a href="{{.RelPermalink}}">{{.Title}}</a></li>
   {{end}}</ul>
 </nav>