Code Review
/
csit.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
review
|
tree
raw
|
inline
| side by side
Fix various pylint violations
[csit.git]
/
resources
/
libraries
/
python
/
NATUtil.py
diff --git
a/resources/libraries/python/NATUtil.py
b/resources/libraries/python/NATUtil.py
index
ab97e05
..
e08a6da
100644
(file)
--- a/
resources/libraries/python/NATUtil.py
+++ b/
resources/libraries/python/NATUtil.py
@@
-197,9
+197,9
@@
class NATUtil(object):
items = line.split(" ")
while "" in items:
items.remove("")
items = line.split(" ")
while "" in items:
items.remove("")
- if
len(items) == 0
:
+ if
not items
:
continue
continue
-
el
if len(items) == 4:
+ if len(items) == 4:
# no ports were returned
data.append({
"local_address": items[0],
# no ports were returned
data.append({
"local_address": items[0],
@@
-246,9
+246,9
@@
class NATUtil(object):
for trash in ("", "vat#"):
while trash in items:
items.remove(trash)
for trash in ("", "vat#"):
while trash in items:
items.remove(trash)
- if
len(items) == 0
:
+ if
not items
:
continue
continue
-
el
if len(items) == 3:
+ if len(items) == 3:
data.append({
# items[0] is the table header - "sw_if_index"
"sw_if_index": items[1],
data.append({
# items[0] is the table header - "sw_if_index"
"sw_if_index": items[1],