<commit_before><%
  branch = if page.parent_id.nil? and page.right_sibling.present? and page.left_sibling.nil?
    "branch_start"
  elsif page.right_sibling.nil?
    "branch_end"
  end

  title = page.title
  title << " <em>(#{t('.hidden')})</em>" unless page.show_in_menu?
  title << " <em>(#{t('.draft')})</em>" if page.draft?
-%>
<li class='clearfix record<%= " #{branch}" if branch.present? %>' id="<%= dom_id(page) -%>">
  <div class='clearfix'>
    <span class='title'><%= title.html_safe %></span>

    <span class='actions'>
      <%= link_to refinery_icon_tag('application_go.png'), page.url,
                  :target => "_blank",
                  :title => t('.view_live_html') %>
      <%= link_to refinery_icon_tag('application_edit.png'), edit_admin_page_url(page),
                  :title => t('admin.pages.edit') %>
      <%= link_to refinery_icon_tag('delete.png'), admin_page_url(page),
                  :class => "cancel confirm-delete",
                  :title => t('admin.pages.delete'),
                  :'data-confirm' => t('shared.admin.delete.message', :title => title.gsub(/\ ?<em>.*<\/em>/, "")),
                  :'data-method' => "delete" if page.deletable? %>
    </span>
  </div>
  <ul class='nested'>
    <% if (children = page.children).any? -%>
        <%= render :partial => 'page', :collection => children %>
    <% end -%>
  </ul>

</li>
<commit_msg>Remove branch variable from page partial because branch_start and branch_end class are managed by js + this way we avoid a lot of unneeded db queries.<commit_after><%
  title = page.title
  title << " <em>(#{t('.hidden')})</em>" unless page.show_in_menu?
  title << " <em>(#{t('.draft')})</em>" if page.draft?
-%>
<li class='clearfix record' id="<%= dom_id(page) -%>">
  <div class='clearfix'>
    <span class='title'><%= title.html_safe %></span>

    <span class='actions'>
      <%= link_to refinery_icon_tag('application_go.png'), page.url,
                  :target => "_blank",
                  :title => t('.view_live_html') %>
      <%= link_to refinery_icon_tag('application_edit.png'), edit_admin_page_url(page),
                  :title => t('admin.pages.edit') %>
      <%= link_to refinery_icon_tag('delete.png'), admin_page_url(page),
                  :class => "cancel confirm-delete",
                  :title => t('admin.pages.delete'),
                  :'data-confirm' => t('shared.admin.delete.message', :title => title.gsub(/\ ?<em>.*<\/em>/, "")),
                  :'data-method' => "delete" if page.deletable? %>
    </span>
  </div>
  <ul class='nested'>
    <% if (children = page.children).any? -%>
        <%= render :partial => 'page', :collection => children %>
    <% end -%>
  </ul>
</li>

{'fraction_non_alphanumeric': 0.20729013254786452, 'fraction_numerical': 0.0, 'mean_word_length': 2.742424242424242, 'pattern_counts': {'":': 0, '<': 62, '<?xml version=': 0, '>': 74, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4152542', 'n_tokens_mistral': 936, 'n_tokens_neox': 895, 'n_words': 175}