hugo

Unnamed repository; edit this file 'description' to name the repository.

git clone git://git.shimmy1996.com/hugo.git
commit 6f424175bfc9faa1c7153523ba460b09f1cd7a7e
parent 3d0dc1acb1089022172f61ed65f6002f3fdb9780
Author: Steve Francia <steve.francia@gmail.com>
Date:   Tue, 20 Aug 2013 20:54:31 -0700

Merge pull request #50 from cabello/patch-2

Check .Prev and .Next pointers before using it
Diffstat:
Mdocs/content/layout/content.md | 8++++++--
1 file changed, 6 insertions(+), 2 deletions(-)
diff --git 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>