planarnetwork / raptor

Implementation of the Route Based Public Transit Algorithm (Raptor)
81 stars 13 forks source link

flatMap is not a function #5

Closed lbt05 closed 4 years ago

lbt05 commented 4 years ago

I'm new to node and try to run your project. And failed to run the test.

  29) RangeQuery
       does not share bestArrivals or routeScanner:
     TypeError: destinationsWithResults.flatMap is not a function
      at GroupStationDepartAfterQuery.getJourneysFromConnections (src/query/GroupStationDepartAfterQuery.ts:88:52)
      at GroupStationDepartAfterQuery.getJourneys (src/query/GroupStationDepartAfterQuery.ts:49:28)
      at GroupStationDepartAfterQuery.plan (src/query/GroupStationDepartAfterQuery.ts:32:26)
      at RangeQuery.plan (src/query/RangeQuery.ts:40:42)
      at Context.it (test/unit/query/RangeQuery.spec.ts:86:26)

I wonder how I can fix this issue.

linusnorton commented 4 years ago

Update to node 12, it's now in LTS

lbt05 commented 4 years ago

Thanks. It works.