diff options
author | Claire <claire.github-309c@sitedethib.com> | 2022-02-07 19:57:06 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-02-07 19:57:06 +0100 |
commit | 52c1b86964caddb99e01ff36e928a524bf66ec0e (patch) | |
tree | 9eb4e6fd9cce35af2e07124c6fda99f5e2d7cce9 /app/workers | |
parent | f1f6ddd5362f40e287857750f5e102206bd0e169 (diff) |
Fix Ruby 2.5 incompatibility (#17465)
Diffstat (limited to 'app/workers')
-rw-r--r-- | app/workers/scheduler/accounts_statuses_cleanup_scheduler.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/app/workers/scheduler/accounts_statuses_cleanup_scheduler.rb b/app/workers/scheduler/accounts_statuses_cleanup_scheduler.rb index f42d4bca6..7195f0ff9 100644 --- a/app/workers/scheduler/accounts_statuses_cleanup_scheduler.rb +++ b/app/workers/scheduler/accounts_statuses_cleanup_scheduler.rb @@ -66,7 +66,7 @@ class Scheduler::AccountsStatusesCleanupScheduler end def compute_budget - threads = Sidekiq::ProcessSet.new.filter { |x| x['queues'].include?('push') }.map { |x| x['concurrency'] }.sum + threads = Sidekiq::ProcessSet.new.select { |x| x['queues'].include?('push') }.map { |x| x['concurrency'] }.sum [PER_THREAD_BUDGET * threads, MAX_BUDGET].min end |