X-Git-Url: https://git.njae.me.uk/?a=blobdiff_plain;f=lib%2Fgraph.njae%2Fedge.rb;h=f38a32b21e693bbf645c25bdcca159579f97dceb;hb=5afeed673400a0d1e2c1c0d6b6f286f65723f405;hp=6581033d2a885bbe4fe8beddf1eddfb38879b50a;hpb=c34def40508c16cfc815fa02c8743d071491af7b;p=graph.njae.git 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