<commit_before><% if @involine.errors.present? %>
  toastr.error('<%= j error_messages_for(@involine) %>');
  $("#messages").show();
  $("#messages").html('<div id="flash_notice" class="alert alert-error"><%= j error_messages_for(@involine) %></div>');
  $("#messages").fadeOut(4000);
<% else %>
  <% if @involine.invoice_id.present? %>
    $("#involines_table_body").append('<%= j render @involine %>');
    $("#invoice_<%= @invoice.id %>_totals").html('<%= j render "financor/invoices/totals", invoice: @invoice %>');
  <% else %>
    $("#estimate_involines_table_body").append('<%= j render "financor/involines/estimate", involine: @involine %>');
  <% end %>
  $('#new_involine').each(function() { this.reset(); });
  $("#involine_name").focus();
  toastr.info('<%= j flash[:notice] %>');
  $("#messages").show();
  $("#messages").html('<div id="flash_notice" class="alert alert-notice"><%= j flash[:notice] %></div>');
  $("#messages").fadeOut(5000);
<% end %><commit_msg>second estimate save error<commit_after><% if @involine.errors.present? %>
  toastr.error('<%= j error_messages_for(@involine) %>');
  $("#messages").show();
  $("#messages").html('<div id="flash_notice" class="alert alert-error"><%= j error_messages_for(@involine) %></div>');
  $("#messages").fadeOut(4000);
<% else %>
  <% if @involine.invoice_id.present? %>
    $("#involines_table_body").append('<%= j render @involine %>');
    $("#invoice_<%= @invoice.id %>_totals").html('<%= j render "financor/invoices/totals", invoice: @invoice %>');
  <% else %>
    $("#estimate_involines_table_body").append('<%= j render "financor/involines/estimate", involine: @involine %>');
  <% end %>
  $('#new_involine').each(function() { this.reset(); });
  <% if @involine.company_id.present? %>
    $("#involine_company_id").select2("val", <%= @involine.company_id %>)
  <% end %>
  $("#involine_name").focus();
  toastr.info('<%= j flash[:notice] %>');
  $("#messages").show();
  $("#messages").html('<div id="flash_notice" class="alert alert-notice"><%= j flash[:notice] %></div>');
  $("#messages").fadeOut(5000);
<% end %>
{'fraction_non_alphanumeric': 0.2707736389684814, 'fraction_numerical': 0.008118433619866285, 'mean_word_length': 6.006688963210703, 'pattern_counts': {'":': 0, '<': 42, '<?xml version=': 0, '>': 42, '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': '7308851', 'n_tokens_mistral': 783, 'n_tokens_neox': 717, 'n_words': 116}