mirror of
https://github.com/public-transport/db-vendo-client.git
synced 2025-02-23 15:19:35 +02:00
stopover: default arrival & departure fields 🐛, >= for collecting journeys
This commit is contained in:
parent
e8f21216a5
commit
d96cbfb228
2 changed files with 4 additions and 2 deletions
2
index.js
2
index.js
|
@ -153,7 +153,7 @@ const createClient = (profile, request = _request) => {
|
|||
j = parse(j)
|
||||
journeys.push(j)
|
||||
|
||||
if (journeys.length === opt.results) { // collected enough
|
||||
if (journeys.length >= opt.results) { // collected enough
|
||||
journeys.laterRef = d.outCtxScrF
|
||||
return journeys
|
||||
}
|
||||
|
|
|
@ -5,7 +5,9 @@
|
|||
const createParseStopover = (profile, stations, lines, remarks, date) => {
|
||||
const parseStopover = (st) => {
|
||||
const res = {
|
||||
station: stations[parseInt(st.locX)] || null
|
||||
station: stations[parseInt(st.locX)] || null,
|
||||
arrival: null,
|
||||
departure: null
|
||||
}
|
||||
if (st.aTimeR || st.aTimeS) {
|
||||
const arr = profile.parseDateTime(profile, date, st.aTimeR || st.aTimeS)
|
||||
|
|
Loading…
Add table
Reference in a new issue