Commit 3c962eab authored by Tiago Peixoto's avatar Tiago Peixoto
Browse files

Fig Graph.edge() behavior with new=True and all_edges=False

parent eca90cc4
......@@ -1459,7 +1459,10 @@ class Graph(object):
edges.append(self.add_edge(s, t))
if all_edges:
return edges
return None
elif len(edges) > 0:
return edges[0]
return None
def edges(self):
"""Return an :meth:`iterator <iterator.__iter__>` over the edges.
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment