<commit_before><div class="nested-fields question-entry not-counted">
  <!-- <div class="msg-preview"></div> -->

  <%= link_to_remove_association raw("<button class=\"close questiondeleter\">&times;</button>"), f, :class => "top-right" %>

  <%= f.input :sequence, :as => :hidden %>

  <%= f.input :text, :label => "Question", :label_html => { :class => "label-bold" }, :as => :text, :input_html => { :class => "input-xlarge question-input", :rows => 2 }, :hint => "<div class='msg-count'></div>" %>
  <%= f.input :question_type, :label => "Format" , :collection=>[['Open Ended','OPEN'],['Multiple Choice','MULTI'],['Yes / No', 'YN']], :include_blank => false, :disabled => (!@poll.new_record? and !@poll.responses.empty?), :input_html => { :class => "question-type span2" } %>

  <div class="options">

    <%= f.simple_fields_for :options, :wrapper => "bootstrap" do |option| %>
      <%= render 'option_fields', :f => option %>
    <% end %>
    
  </div>
    <%= link_to_add_association 'Add option', f, :options, :"data-association-insertion-method" => :append, :class => "controls add-option-button"%>

</div>
<commit_msg>Deleting a question with responses now prompts the user for confirmation<commit_after><div class="nested-fields question-entry not-counted">
  <!-- <div class="msg-preview"></div> -->

  <%= link_to_remove_association raw("<button class=\"close questiondeleter\">&times;</button>"), f, :class => "top-right", :confirm => f.object.responses.empty? ? "" : "This question already has responses! Deleting it will also delete responses. Are you sure?"  %>

  <%= f.input :sequence, :as => :hidden %>

  <%= f.input :text, :label => "Question", :label_html => { :class => "label-bold" }, :as => :text, :input_html => { :class => "input-xlarge question-input", :rows => 2 }, :hint => "<div class='msg-count'></div>" %>
  <%= f.input :question_type, :label => "Format" , :collection=>[['Open Ended','OPEN'],['Multiple Choice','MULTI'],['Yes / No', 'YN']], :include_blank => false, :disabled => (!@poll.new_record? and !@poll.responses.empty?), :input_html => { :class => "question-type span2" } %>

  <div class="options">

    <%= f.simple_fields_for :options, :wrapper => "bootstrap" do |option| %>
      <%= render 'option_fields', :f => option %>
    <% end %>
    
  </div>
    <%= link_to_add_association 'Add option', f, :options, :"data-association-insertion-method" => :append, :class => "controls add-option-button"%>

</div>

{'fraction_non_alphanumeric': 0.22914122914122914, 'fraction_numerical': 0.001628001628001628, 'mean_word_length': 4.637614678899083, 'pattern_counts': {'":': 0, '<': 41, '<?xml version=': 0, '>': 82, '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': '1873940', 'n_tokens_mistral': 842, 'n_tokens_neox': 801, 'n_words': 184}