Merge pull request #3366 from tancnle/email-retry-jobs-count

A shorter and more concise version of select..size
This commit is contained in:
Régis Hanol 2015-04-12 17:26:38 +02:00
commit 076bfeeb22
1 changed files with 1 additions and 1 deletions

View File

@ -14,7 +14,7 @@ module Jobs
end
def self.num_email_retry_jobs
Sidekiq::RetrySet.new.select { |job| job.klass =~ /Email$/ }.size
Sidekiq::RetrySet.new.count { |job| job.klass =~ /Email$/ }
end
class Base