diff options
author | Eric Eastwood <contact@ericeastwood.com> | 2018-02-06 09:51:09 +0300 |
---|---|---|
committer | Eric Eastwood <contact@ericeastwood.com> | 2018-02-06 09:51:09 +0300 |
commit | 686541411e8a7c37b2c8745ebb8bc4543f59e815 (patch) | |
tree | cb84d86b1401a5351a6a2b1c11cb675eb1dcbf94 /layouts | |
parent | 2928f348ce82924fcdc7ba3a641156d13152435f (diff) |
Add check for @item before usage so that non-existant items don't complain locally
Diffstat (limited to 'layouts')
-rw-r--r-- | layouts/header.html | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/layouts/header.html b/layouts/header.html index 8ef46795..a69af72e 100644 --- a/layouts/header.html +++ b/layouts/header.html @@ -8,7 +8,7 @@ <ul class="nav"> <li class="search"><input type="text" class="docsearch" placeholder="Search"></li> <% @config[:products].each do |name, product| %> - <% if product[:expose] == true %> + <% if product[:expose] == true && @items["/#{product[:slug]}/#{product[:index_file]}"] %> <li class="nav-item"> <a href="<%= @items["/#{product[:slug]}/#{product[:index_file]}"].path %>"> <%= product[:short_name] %> |