Skip to content

Commit

Permalink
pass E722, E741 flake8 rules
Browse files Browse the repository at this point in the history
  • Loading branch information
nad2000 authored and bugchecker committed Nov 2, 2017
1 parent 5127b6c commit ab18cb3
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
8 changes: 4 additions & 4 deletions flask_admin/contrib/sqla/tools.py
Original file line number Diff line number Diff line change
Expand Up @@ -75,14 +75,14 @@ def tuple_operator_in(model_pk, ids):
The returning operator can be used within a filter(), as it is just an or_ operator
"""
l = []
ands = []
for id in ids:
k = []
for i in range(len(model_pk)):
k.append(eq(model_pk[i], id[i]))
l.append(and_(*k))
if len(l) >= 1:
return or_(*l)
ands.append(and_(*k))
if len(ands) >= 1:
return or_(*ands)
else:
return None

Expand Down
2 changes: 1 addition & 1 deletion tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ skip_missing_interpreters = true

[flake8]
max_line_length = 120
ignore = E402
ignore = E402,E722

[testenv]
usedevelop = true
Expand Down

0 comments on commit ab18cb3

Please sign in to comment.