<commit_before>class DownloadStatusWorker
  include Sidekiq::Worker
  include Sidetiq::Schedulable

  recurrence { minutely 5 }

  def perform
    download = get_oldest_download
    if download
      download.refresh_status
    end
  end

  private

  def get_oldest_download
    Download.order(:status_refreshed_at).first
  end
end<commit_msg>fixed a bug that prevented to check the availibility of new downloads<commit_after>class DownloadStatusWorker
  include Sidekiq::Worker
  include Sidetiq::Schedulable

  recurrence { minutely 5 }

  def perform
    download = get_oldest_download
    if download
      download.refresh_status
    end
  end

  private

  def get_oldest_download
    Download.where(:status_refreshed_at => nil).first || Download.order(:status_refreshed_at).first
  end
end
{'fraction_non_alphanumeric': 0.05144291091593475, 'fraction_numerical': 0.002509410288582183, 'mean_word_length': 3.9875, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 4, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 16, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3936664', 'n_tokens_mistral': 245, 'n_tokens_neox': 234, 'n_words': 60}