diff options
Diffstat (limited to 'app/workers/update_project_statistics_worker.rb')
-rw-r--r-- | app/workers/update_project_statistics_worker.rb | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/app/workers/update_project_statistics_worker.rb b/app/workers/update_project_statistics_worker.rb index 4a32753ac70..45a6cc8f476 100644 --- a/app/workers/update_project_statistics_worker.rb +++ b/app/workers/update_project_statistics_worker.rb @@ -13,11 +13,9 @@ class UpdateProjectStatisticsWorker # rubocop:disable Scalability/IdempotentWork # project_id - The ID of the project for which to flush the cache. # statistics - An Array containing columns from ProjectStatistics to # refresh, if empty all columns will be refreshed - # rubocop: disable CodeReuse/ActiveRecord def perform(project_id, statistics = []) - project = Project.find_by(id: project_id) + project = Project.find_by_id(project_id) Projects::UpdateStatisticsService.new(project, nil, statistics: statistics).execute end - # rubocop: enable CodeReuse/ActiveRecord end |