Skip to content
This repository has been archived by the owner on Dec 21, 2023. It is now read-only.

Commit

Permalink
Fix Ruby 2.5 incompatibility (mastodon#17465)
Browse files Browse the repository at this point in the history
  • Loading branch information
ClearlyClaire authored Feb 7, 2022
1 parent f1f6ddd commit 52c1b86
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ def perform
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

Expand Down

0 comments on commit 52c1b86

Please sign in to comment.