mirror of
https://salsa.debian.org/freeipa-team/freeipa.git
synced 2024-12-23 07:33:27 -06:00
ipapython/graph.py redundant variable fix
Changed deletion of edges in remove_vertex method because there's no need to store redundant variable in memory. Reviewed-By: Alexander Bokovoy <abokovoy@redhat.com> Reviewed-By: Martin Basti <mbasti@redhat.com>
This commit is contained in:
parent
fe913b9c9f
commit
c39da523ad
@ -54,8 +54,9 @@ class Graph(object):
|
||||
adj[:] = [v for v in adj if v != vertex]
|
||||
|
||||
# delete edges
|
||||
edges = [e for e in self.edges if e[0] != vertex and e[1] != vertex]
|
||||
self.edges[:] = edges
|
||||
self.edges = [
|
||||
e for e in self.edges if e[0] != vertex and e[1] != vertex
|
||||
]
|
||||
|
||||
def get_tails(self, head):
|
||||
"""
|
||||
|
Loading…
Reference in New Issue
Block a user