summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDanilo Cabello <danilo.cabello@gmail.com>2013-08-20 12:13:27 -0400
committerDanilo Cabello <danilo.cabello@gmail.com>2013-08-20 12:13:27 -0400
commitacd5ea0e75cc577c55b80e40fc26ed7c2b66ea63 (patch)
tree289650276e9291cf997d333d83fc8f683df0f873
parenteff8457ac91e337b81876271aca31bf4d61e09f1 (diff)
Check .Prev and .Next pointers before using it
-rw-r--r--docs/content/layout/content.md8
1 files changed, 6 insertions, 2 deletions
diff --git a/docs/content/layout/content.md b/docs/content/layout/content.md
index e6df58867..7bf335e2a 100644
--- a/docs/content/layout/content.md
+++ b/docs/content/layout/content.md
@@ -65,8 +65,12 @@ It makes use of [chrome templates](/layout/chrome)
</ul>
</div>
<div>
- <a class="previous" href="{{.Prev.Permalink}}"> {{.Prev.Title}}</a>
- <a class="next" href="{{.Next.Permalink}}"> {{.Next.Title}}</a>
+ {{ if .Prev }}
+ <a class="previous" href="{{.Prev.Permalink}}"> {{.Prev.Title}}</a>
+ {{ end }}
+ {{ if .Next }}
+ <a class="next" href="{{.Next.Permalink}}"> {{.Next.Title}}</a>
+ {{ end }}
</div>
</aside>