<commit_before>class BankHolidayExcluder
  def call
    ActiveRecord::Base.transaction do
      bank_holiday_observing_organisation_ids.each do |organisation_id|
        create_all_day_bank_holidays_for_organisation(organisation_id)
      end

      delete_existing_bank_holidays
    end
  end

  private

  def permitted_date_pairs
    [
      ['2020-05-08 00:00:00', '2020-05-08 23:59:59'],
      ['2020-05-25 00:00:00', '2020-05-25 23:59:59'],
      ['2020-08-31 00:00:00', '2020-08-31 23:59:59']
    ]
  end

  def create_all_day_bank_holidays_for_organisation(organisation_id) # rubocop:disable MethodLength
    active_guider_ids_for_organisation(organisation_id).each do |guider_id|
      permitted_date_pairs.each do |date_pair|
        Holiday.create!(
          user_id: guider_id,
          all_day: true,
          bank_holiday: false,<commit_msg>Add extra exclusions for CAS<commit_after>class BankHolidayExcluder
  def call
    ActiveRecord::Base.transaction do
      bank_holiday_observing_organisation_ids.each do |organisation_id|
        create_all_day_bank_holidays_for_organisation(organisation_id)
      end

      delete_existing_bank_holidays
    end
  end

  private

  def permitted_date_pairs
    [
      ['2021-04-02 00:00:00', '2021-04-02 23:59:59'],
      ['2021-04-05 00:00:00', '2021-04-05 23:59:59']
    ]
  end

  def create_all_day_bank_holidays_for_organisation(organisation_id) # rubocop:disable MethodLength
    active_guider_ids_for_organisation(organisation_id).each do |guider_id|
      permitted_date_pairs.each do |date_pair|
        Holiday.create!(
          user_id: guider_id,
          all_day: true,
          bank_holiday: false,
{'fraction_non_alphanumeric': 0.08706022659511031, 'fraction_numerical': 0.08348240906380441, 'mean_word_length': 3.522911051212938, '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': '2624621', 'n_tokens_mistral': 685, 'n_tokens_neox': 595, 'n_words': 93}