diff --git a/lib/sidekiq/api.rb b/lib/sidekiq/api.rb index 62855e0f..cb38aa2e 100644 --- a/lib/sidekiq/api.rb +++ b/lib/sidekiq/api.rb @@ -731,7 +731,7 @@ module Sidekiq next if info.nil? hash = Sidekiq.load_json(info) - yield Process.new(hash.merge('busy' => busy.to_i, 'beat' => at_s.to_f, 'quiet' => quiet)), leader + yield Process.new(hash.merge('busy' => busy.to_i, 'beat' => at_s.to_f, 'quiet' => quiet)) end end diff --git a/web/views/busy.erb b/web/views/busy.erb index 1a760534..32079571 100644 --- a/web/views/busy.erb +++ b/web/views/busy.erb @@ -22,7 +22,8 @@ <%= t('Busy') %>   - <% processes.each do |process,leader| %> + <% lead = processes.leader %> + <% processes.each do |process| %> <%= "#{process['hostname']}:#{process['pid']}" %> @@ -33,7 +34,7 @@ <% if process.stopping? %> quiet <% end %> - <% if process.identity == leader %> + <% if process.identity == lead %> leader <% end %>