summaryrefslogtreecommitdiff
path: root/django/db/migrations/graph.py
diff options
context:
space:
mode:
authorTim Graham <timograham@gmail.com>2016-04-03 20:37:32 -0400
committerTim Graham <timograham@gmail.com>2016-04-04 17:14:26 -0400
commit2cd2d188516475ddf256e6267cd82c495fb5c430 (patch)
tree1a7c3c167c1576923c7c4f5544495face5bd7327 /django/db/migrations/graph.py
parentd356bb653f4d90ae9809e5a051791ded39010c38 (diff)
downloaddjango-2cd2d188516475ddf256e6267cd82c495fb5c430.tar.gz
Fixed W503 flake8 warnings.
Diffstat (limited to 'django/db/migrations/graph.py')
-rw-r--r--django/db/migrations/graph.py6
1 files changed, 2 insertions, 4 deletions
diff --git a/django/db/migrations/graph.py b/django/db/migrations/graph.py
index f324ba5551..6ba4ec129b 100644
--- a/django/db/migrations/graph.py
+++ b/django/db/migrations/graph.py
@@ -206,8 +206,7 @@ class MigrationGraph(object):
"""
roots = set()
for node in self.nodes:
- if (not any(key[0] == node[0] for key in self.node_map[node].parents)
- and (not app or app == node[0])):
+ if not any(key[0] == node[0] for key in self.node_map[node].parents) and (not app or app == node[0]):
roots.add(node)
return sorted(roots)
@@ -221,8 +220,7 @@ class MigrationGraph(object):
"""
leaves = set()
for node in self.nodes:
- if (not any(key[0] == node[0] for key in self.node_map[node].children)
- and (not app or app == node[0])):
+ if not any(key[0] == node[0] for key in self.node_map[node].children) and (not app or app == node[0]):
leaves.add(node)
return sorted(leaves)