% css = if ((defined?(apply_css) && apply_css) || !defined?(apply_css)) and (classes = css_for_menu_branch(menu_branch, menu_branch_counter, sibling_count||=nil)).any? " class='#{classes.join(' ')}'" end dom_id = (" id='item_#{menu_branch_counter}'" if menu_branch.parent_id.nil? and menu_branch.title.present?) @menu_pages.reject! { |branch| branch == menu_branch } # Remove page from the array, so that future searching will be faster. children = @menu_pages.select { |p| p.parent_id == menu_branch.id && p.in_menu? } -%>