gtfs 4.14.1 → 4.14.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/bin/gtfs-export.js.map +1 -1
- package/dist/bin/gtfs-import.js +2 -2
- package/dist/bin/gtfs-import.js.map +1 -1
- package/dist/bin/gtfsrealtime-update.js +139 -2
- package/dist/bin/gtfsrealtime-update.js.map +1 -1
- package/dist/index.js +16 -14
- package/dist/index.js.map +1 -1
- package/package.json +5 -2
package/dist/bin/gtfs-import.js
CHANGED
|
@@ -3526,12 +3526,12 @@ var updateRealtimeData = async (task) => {
|
|
|
3526
3526
|
task.log(`Download successful`);
|
|
3527
3527
|
let totalLineCount = 0;
|
|
3528
3528
|
for (const entity of gtfsRealtimeData.entity) {
|
|
3529
|
-
const fieldValues =
|
|
3529
|
+
const fieldValues = vehiclePositions.schema.map(
|
|
3530
3530
|
(column) => prepareRealtimeValue(entity, column, task)
|
|
3531
3531
|
);
|
|
3532
3532
|
try {
|
|
3533
3533
|
db.prepare(
|
|
3534
|
-
`REPLACE INTO ${
|
|
3534
|
+
`REPLACE INTO ${vehiclePositions.filenameBase} (${vehiclePositions.schema.map((column) => column.name).join(", ")}) VALUES (${fieldValues.join(", ")})`
|
|
3535
3535
|
).run();
|
|
3536
3536
|
} catch (error) {
|
|
3537
3537
|
task.logWarning("Import error: " + error.message);
|