From: Neil Smith Date: Mon, 26 Sep 2011 11:12:48 +0000 (+0100) Subject: Tweak in edge.rb X-Git-Url: https://git.njae.me.uk/?a=commitdiff_plain;h=7ec68a4c02bf1e55744b274fe2f19f591f357a8b;p=graph.njae.git Tweak in edge.rb --- diff --git a/lib/graph.njae/edge.rb b/lib/graph.njae/edge.rb index 6581033..f38a32b 100644 --- a/lib/graph.njae/edge.rb +++ b/lib/graph.njae/edge.rb @@ -31,7 +31,7 @@ module GraphNjae # Return the connection object that joins this Edge to the specified Vertex def connection_at(vertex) - self.connections.select {|c| c.end.equal? vertex}.first + self.connections.find {|c| c.end.equal? vertex} end end