Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Mutalyzer
mutalyzer2
Commits
25fa9bd9
Commit
25fa9bd9
authored
Nov 02, 2015
by
Vermaat
Browse files
Merge pull request #106 from mutalyzer/fix-admin-batch-jobs
Fix crash listing zero batch jobs in admin
parents
afa9ded0
a9e69782
Changes
1
Hide whitespace changes
Inline
Side-by-side
mutalyzer/entrypoints/admin.py
View file @
25fa9bd9
...
...
@@ -176,6 +176,9 @@ def list_batch_jobs():
).
label
(
'count'
)
).
order_by
(
BatchJob
.
added
.
asc
()).
all
()
if
len
(
batch_jobs_with_counts
)
<
1
:
return
lengths
=
{
'id_len'
:
max
(
len
(
str
(
j
.
id
))
for
j
,
_
in
batch_jobs_with_counts
),
'type_len'
:
max
(
len
(
j
.
job_type
)
for
j
,
_
in
batch_jobs_with_counts
),
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment