<commit_before>module PartialsVisibilityHelper
  def show_section_case_summary?
    return false unless moderated_assessment.submitted?
    return true if current_subject.lead?(@form_answer) || current_subject.primary?(@form_answer)
  end

  def show_section_appraisal_moderated?
    policy(@form_answer).show_section_appraisal_moderated?
  end

  def show_winners_section?
    @form_answer.awarded? || @form_answer.recommended?
  end

  def show_feedback_section?
    @form_answer.unsuccessful? && !@form_answer.promotion? &&
      !current_subject.try(:secondary?, @form_answer)
  end

  def show_press_summary_subsection?
    (@form_answer.awarded? || @form_answer.recommended?) &&
      !current_subject.try(:secondary?, @form_answer)
  end

  def show_palace_attendees_subsection?
    @form_answer.awarded? && !current_subject.try(:secondary?, @form_answer)
  end

  def show_bulk_assignment?
    current_subject.categories_as_lead.include?(category_picker.current_award_type)
  end

  def show_form_answer_attachment?(attachment)
    current_subject.is_a?(Admin) || !attachment.restricted_to_admin?
  end

  def show_remove_form_answer_attachment?(attachment)
    attachment.uploaded_not_by_user? && policy(attachment).destroy?
  end
end
<commit_msg>'Press Book Notes' options needs to also appear on 'Reserved' cases.<commit_after>module PartialsVisibilityHelper
  def show_section_case_summary?
    return false unless moderated_assessment.submitted?
    return true if current_subject.lead?(@form_answer) || current_subject.primary?(@form_answer)
  end

  def show_section_appraisal_moderated?
    policy(@form_answer).show_section_appraisal_moderated?
  end

  def show_winners_section?
    @form_answer.awarded? || @form_answer.recommended? || @form_answer.reserved?
  end

  def show_feedback_section?
    @form_answer.unsuccessful? && !@form_answer.promotion? &&
      !current_subject.try(:secondary?, @form_answer)
  end

  def show_press_summary_subsection?
    (@form_answer.awarded? || @form_answer.recommended? || @form_answer.reserved?) &&
      !current_subject.try(:secondary?, @form_answer)
  end

  def show_palace_attendees_subsection?
    @form_answer.awarded? && !current_subject.try(:secondary?, @form_answer)
  end

  def show_bulk_assignment?
    current_subject.categories_as_lead.include?(category_picker.current_award_type)
  end

  def show_form_answer_attachment?(attachment)
    current_subject.is_a?(Admin) || !attachment.restricted_to_admin?
  end

  def show_remove_form_answer_attachment?(attachment)
    attachment.uploaded_not_by_user? && policy(attachment).destroy?
  end
end

{'fraction_non_alphanumeric': 0.0958381061473845, 'fraction_numerical': 0.0, 'mean_word_length': 5.787564766839378, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, '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': '5204455', 'n_tokens_mistral': 865, 'n_tokens_neox': 838, 'n_words': 128}