Fix swapped options for auto and bicycle routing (#694)
This commit is contained in:
@@ -62,12 +62,11 @@ export async function calculateRouteBetween(startLat: number, startLon: number,
|
|||||||
let costingBody;
|
let costingBody;
|
||||||
switch (options.modeOfTransport) {
|
switch (options.modeOfTransport) {
|
||||||
case "bicycle":
|
case "bicycle":
|
||||||
costingBody = { "costing": options.modeOfTransport, "costing_options": { [options.modeOfTransport]: options.autoOptions } }
|
|
||||||
break;
|
|
||||||
case "auto":
|
|
||||||
costingBody = { "costing": options.modeOfTransport, "costing_options": { [options.modeOfTransport]: options.bicycleOptions } }
|
costingBody = { "costing": options.modeOfTransport, "costing_options": { [options.modeOfTransport]: options.bicycleOptions } }
|
||||||
break;
|
break;
|
||||||
|
case "auto":
|
||||||
|
costingBody = { "costing": options.modeOfTransport, "costing_options": { [options.modeOfTransport]: options.autoOptions } }
|
||||||
|
break;
|
||||||
case "pedestrian":
|
case "pedestrian":
|
||||||
costingBody = { "costing": options.modeOfTransport, "costing_options": { [options.modeOfTransport]: options.pedestrianOptions } }
|
costingBody = { "costing": options.modeOfTransport, "costing_options": { [options.modeOfTransport]: options.pedestrianOptions } }
|
||||||
break;
|
break;
|
||||||
|
|||||||
Reference in New Issue
Block a user