mirror of
https://fuchsia.googlesource.com/third_party/github.com/pylint-dev/pylint
synced 2024-09-21 07:58:04 +00:00
Rewrite the operation with a ternary if in order to be clearer.
This commit is contained in:
parent
7fafa3a64b
commit
5b9d4b628a
|
@ -76,7 +76,7 @@ class HTMLWriter(BaseWriter):
|
|||
elif i+1 == len(table_content) and layout.rrheaders:
|
||||
self.writeln(u'<tr class="header">')
|
||||
else:
|
||||
self.writeln(u'<tr class="%s">' % (i%2 and 'even' or 'odd'))
|
||||
self.writeln(u'<tr class="%s">' % ('even' if i % 2 else u'odd'))
|
||||
for j, cell in enumerate(row):
|
||||
cell = cell or u' '
|
||||
if (layout.rheaders and i == 0) or \
|
||||
|
|
Loading…
Reference in New Issue
Block a user