From ae4203b25df06783c542d9ae4c2b03757dcc0bf3 Mon Sep 17 00:00:00 2001 From: Jannis R Date: Fri, 1 Jun 2018 15:05:54 +0200 Subject: [PATCH] vbb-lines@4 --- build.js | 10 +++++----- package.json | 2 +- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/build.js b/build.js index 3584173..16830b4 100644 --- a/build.js +++ b/build.js @@ -25,15 +25,15 @@ lines('all') .on('data', (line) => { for (let variant of line.variants) { // for (let stopId of variant) { - for (let i = 0; i < (variant.length - 1); i++) { - const from = stationOf[variant[i]] + for (let i = 0; i < (variant.stops.length - 1); i++) { + const from = stationOf[variant.stops[i]] if (!from) { - console.error('unkown station for stop ' + variant[i]) + console.error('unkown station for stop ' + variant.stops[i]) continue } - const to = stationOf[variant[i + 1]] + const to = stationOf[variant.stops[i + 1]] if (!to) { - console.error('unkown station for stop ' + variant[i + 1]) + console.error('unkown station for stop ' + variant.stops[i + 1]) continue } if (from === to) continue // wat diff --git a/package.json b/package.json index 1fd99b6..bddd145 100644 --- a/package.json +++ b/package.json @@ -24,7 +24,7 @@ "devDependencies": { "tap-min": "^1.2.1", "tape": "^4.6.3", - "vbb-lines": "^3.3.0", + "vbb-lines": "^4.1.0", "vbb-stations": "^6.2.0" }, "scripts": {