Skip to content

Commit

Permalink
Accra - fix stoparea stop_id
Browse files Browse the repository at this point in the history
  • Loading branch information
Pascal Rhod authored and grote committed Oct 7, 2017
1 parent c22af7b commit 5bd24ab
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion creators/accra/stops_creator_accra.py
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,8 @@ def create_stop_point(stop_data, schedule):
)
return gtfs_stop_point

def get_stop_id(stop):
return stop.id

class StopsCreatorAccra(StopsCreator):

Expand All @@ -64,7 +66,7 @@ def add_stops_to_schedule(self, schedule, data):
for a_stop_name in stops_by_name:
stop_areas = []

for a_stop_point in stops_by_name[a_stop_name]:
for a_stop_point in sorted(stops_by_name[a_stop_name], key=get_stop_id):
gtfs_stop_point = create_stop_point(a_stop_point, schedule)
stop_point_has_parent_location = False
for a_stop_area in stop_areas:
Expand Down

0 comments on commit 5bd24ab

Please sign in to comment.