Commit
Author: Bradley Cicenas [bradley@vektor.nyc]
Hash: 15c64a4f620de0bfcf8d6173ba39cac71e4030ed
Timestamp: Fri, 05 Jul 2019 14:12:18 +0000 (5 years ago)

+1 -1 +/-1 browse
fix shortest call arg
1diff --git a/graph.go b/graph.go
2index 213139e..0f0b68f 100644
3--- a/graph.go
4+++ b/graph.go
5 @@ -36,7 +36,7 @@ func Load(airports AirportMap, routes []Route, weighters ...Weighter) graph.Grap
6
7 func Find(start, end Airport, g graph.Graph) Itinerary {
8 shortest := path.DijkstraFrom(start, g)
9- path, weight := shortest.To(end)
10+ path, weight := shortest.To(end.ID())
11 var airports []Airport
12 for _, p := range path {
13 airports = append(airports, p.(Airport))