This commit is contained in:
Vincent Driessen 2011-11-28 14:14:11 +01:00
parent da228dd76c
commit 2ff383162c
1 changed files with 1 additions and 1 deletions

View File

@ -95,7 +95,7 @@ def show_workers(args):
queues[q].append(w) queues[q].append(w)
if args.by_queue: if args.by_queue:
max_qname = max(map(lambda q: len(q.name), queues.keys())) max_qname = max(map(lambda q: len(q.name), queues.keys())) if queues else 0
for q in queues: for q in queues:
if queues[q]: if queues[q]:
queues_str = ", ".join(sorted(map(lambda w: '%s (%s)' % (w.name, state_symbol(w.state)), queues[q]))) queues_str = ", ".join(sorted(map(lambda w: '%s (%s)' % (w.name, state_symbol(w.state)), queues[q])))