<commit_before><% if @presenter %>
  <% if @answer_sheet.frozen? && !@answer_sheet.reference? %>
    Current File: <%= link_to(answer.attachment_file_name, answer.attachment.url) %>
  <% else %>
      <div class="uploader">
        <input id="<%= dom_id(attachment_field) %>_file_uploader" name="image_uploader" type="file" />
        <!-- width: 350px -->
        <span id="<%= dom_id(attachment_field) %>_filename">
        <% answer = attachment_field.responses(@answer_sheet).first
          if answer.present? %>
            Current File: <%= link_to(answer.attachment_file_name, answer.attachment.url) %>
          <% end %>
        </span>
      </div>
      
      <script type="text/javascript" charset="utf-8">
        <% session_key_name = Rails.application.config.session_options[:key] %>
        $('#<%= dom_id(attachment_field) %>_file_uploader').uploadify({
            uploader        : '<%= asset_path "fe/uploadify/uploadify.swf" %>',
            script          : '<%= save_file_answer_sheet_page_path(@presenter.active_answer_sheet, @page, :question_id => attachment_field.id) %>',
            fileDesc        : 'Pick a file',
            fileExt         : '*.*',
            auto            : true,
            sizeLimit       : <%= 100.megabytes %>,
            width           : 350,
            height          : 30,
            multi           : true,
            simUploadLimit  : 2,
            method          : 'POST',
            cancelImg       : '<%= asset_path "fe/uploadify/cancel.png" %>',
            onComplete      : function(a, b, c, response){ eval(response); },
            buttonText      : 'Attach a file',
            scriptData      : {
              '_http_accept': 'application/javascript',
              '_method': 'post',
              '<%= session_key_name %>' : encodeURIComponent('<%= u cookies[session_key_name] %>'),
              'authenticity_token': encodeURIComponent('<%= u form_authenticity_token %>')
            }
        });
      </script>
  <% end %>
<% end %><commit_msg>Fix url reference for attachments<commit_after><% if @presenter %>
  <% if @answer_sheet.frozen? && !@answer_sheet.reference? %>
    Current File: <%= link_to(answer.attachment_file_name, answer.attachment.url) %>
  <% else %>
      <div class="uploader">
        <input id="<%= dom_id(attachment_field) %>_file_uploader" name="image_uploader" type="file" />
        <!-- width: 350px -->
        <span id="<%= dom_id(attachment_field) %>_filename">
        <% answer = attachment_field.responses(@answer_sheet).first
          if answer.present? %>
            Current File: <%= link_to(answer.attachment_file_name, answer.attachment.url) %>
          <% end %>
        </span>
      </div>
      
      <script type="text/javascript" charset="utf-8">
        <% session_key_name = Rails.application.config.session_options[:key] %>
        $('#<%= dom_id(attachment_field) %>_file_uploader').uploadify({
            uploader        : '<%= asset_path "fe/uploadify/uploadify.swf" %>',
            script          : '<%= save_file_fe_answer_sheet_page_path(@presenter.active_answer_sheet, @page, :question_id => attachment_field.id) %>',
            fileDesc        : 'Pick a file',
            fileExt         : '*.*',
            auto            : true,
            sizeLimit       : <%= 100.megabytes %>,
            width           : 350,
            height          : 30,
            multi           : true,
            simUploadLimit  : 2,
            method          : 'POST',
            cancelImg       : '<%= asset_path "fe/uploadify/cancel.png" %>',
            onComplete      : function(a, b, c, response){ eval(response); },
            buttonText      : 'Attach a file',
            scriptData      : {
              '_http_accept': 'application/javascript',
              '_method': 'post',
              '<%= session_key_name %>' : encodeURIComponent('<%= u cookies[session_key_name] %>'),
              'authenticity_token': encodeURIComponent('<%= u form_authenticity_token %>')
            }
        });
      </script>
  <% end %>
<% end %>
{'fraction_non_alphanumeric': 0.15181840371003172, 'fraction_numerical': 0.006346106907493288, 'mean_word_length': 1.971718636693256, 'pattern_counts': {'":': 0, '<': 59, '<?xml version=': 0, '>': 61, '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': '7145297', 'n_tokens_mistral': 1255, 'n_tokens_neox': 1152, 'n_words': 202}