Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 10 additions & 1 deletion patchwork/templatetags/patch.py
Original file line number Diff line number Diff line change
Expand Up @@ -39,12 +39,21 @@ def patch_checks(patch):
counts = patch.check_count

check_elements = []
all_empty = True
for state in required:
if counts[state]:
all_empty = False
break

for state in required[::-1]:
if counts[state]:
color = dict(Check.STATE_CHOICES).get(state)
count = str(counts[state])
else:
color = ''
if all_empty:
color = 'nochecks'
else:
color = ''
count = '-'

check_elements.append(
Expand Down
Loading