<% var previous = obj.page.previousPage || null; var next = obj.page.nextPage || null; %> <% if (previous || next) { %>
<% if (previous) { %> <%= previous.title %> <% } %> <% if (next) { %> <%= next.title %> <% } %>
<% } %>