From d57c67d9afb11e3049c61a0ab0556d52eaa48a70 Mon Sep 17 00:00:00 2001 From: itantik Date: Tue, 30 Dec 2014 22:08:41 +0100 Subject: [PATCH] 'longname' property of tutorials is undefined therefore uniqueness checking causes the navigation displays only one tutorial. Items without 'longname' should be omitted from checking. --- templates/default/publish.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/templates/default/publish.js b/templates/default/publish.js index c94d5be6..1c49130b 100644 --- a/templates/default/publish.js +++ b/templates/default/publish.js @@ -295,7 +295,10 @@ function buildMemberNav(items, itemHeading, itemsSeen, linktoFn) { var itemsNav = ''; items.forEach(function(item) { - if ( !hasOwnProp.call(itemsSeen, item.longname) ) { + if ( !hasOwnProp.call(item, 'longname') ) { + itemsNav += '
  • ' + linktoFn('', item.name) + '
  • '; + } + else if ( !hasOwnProp.call(itemsSeen, item.longname) ) { itemsNav += '
  • ' + linktoFn(item.longname, item.name.replace(/^module:/, '')) + '
  • '; itemsSeen[item.longname] = true; }