diff options
author | Danilo Cabello <danilo.cabello@gmail.com> | 2013-08-20 12:13:27 -0400 |
---|---|---|
committer | Danilo Cabello <danilo.cabello@gmail.com> | 2013-08-20 12:13:27 -0400 |
commit | acd5ea0e75cc577c55b80e40fc26ed7c2b66ea63 (patch) | |
tree | 289650276e9291cf997d333d83fc8f683df0f873 | |
parent | eff8457ac91e337b81876271aca31bf4d61e09f1 (diff) |
Check .Prev and .Next pointers before using it
-rw-r--r-- | docs/content/layout/content.md | 8 |
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> |