X-Git-Url: https://git.openstreetmap.org/rails.git/blobdiff_plain/09900654e6ea5b111e67aa8f5eb1c38e213e653b..4a9f20a4858f6f647bb72128406163d93eccb720:/app/assets/javascripts/index/directions/osrm.js?ds=sidebyside diff --git a/app/assets/javascripts/index/directions/osrm.js b/app/assets/javascripts/index/directions/osrm.js index 5c29f6c4d..e31c053ef 100644 --- a/app/assets/javascripts/index/directions/osrm.js +++ b/app/assets/javascripts/index/directions/osrm.js @@ -111,7 +111,11 @@ function OSRMEngine() { } if (step.maneuver.type.match(/rotary|roundabout/)) { - instText += I18n.t(template + '_with_exit', { exit: step.maneuver.exit, name: name } ); + if (step.maneuver.exit) { + instText += I18n.t(template + '_with_exit', { exit: step.maneuver.exit, name: name } ); + } else { + instText += I18n.t(template + '_without_exit', { name: name } ); + } } else if (step.maneuver.type.match(/on ramp|off ramp/)) { if (step.destinations) { if (namedRoad) {