<% var that = this; %> <% if (!that.collection.isEmpty()) { %> <% } %>