summaryrefslogtreecommitdiff
path: root/app/workers/project_daily_statistics_worker.rb
blob: 101f5c28459a6fcad511e86a0c07e03b7319bc3e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
# frozen_string_literal: true

class ProjectDailyStatisticsWorker
  include ApplicationWorker

  def perform(project_id)
    project = Project.find_by_id(project_id)

    return unless project&.repository&.exists?

    Projects::FetchStatisticsIncrementService.new(project).execute
  end
end