This commit is contained in:
2025-11-15 17:53:50 +01:00
parent 1bebded484
commit 5dc296805a
15 changed files with 634 additions and 688 deletions

View File

@@ -41,8 +41,8 @@ func LoadTripData(path string) (*TripData, error) {
err = ParseRoutes(f, func(r types.Route) {
tp.Routes[r.RouteID] = &r
if ag, ok := tp.Agencies[r.AgencyID]; ok {
r.Agency = ag
ag.AddRoute(&r)
r.SetAgency(ag)
// ag.AddRoute(&r)
}
})
case "stops":
@@ -88,7 +88,7 @@ func LoadTripData(path string) (*TripData, error) {
//transfers = append(transfers, tr)
stop, ok := tp.Stops[tr.FromStopId]
if ok {
stop.AddTransfer(&tr)
stop.AddTransfer(&tr, tp.Stops[tr.ToStopId])
} else {
log.Printf("stop %s not found for transfer", tr.FromStopId)
}