Look for locale specific names
This commit is contained in:
parent
cddec72be5
commit
2992564276
1 changed files with 8 additions and 1 deletions
|
@ -112,7 +112,14 @@ OSM.Query = function(map) {
|
|||
}
|
||||
|
||||
function featureName(feature) {
|
||||
var tags = feature.tags;
|
||||
var tags = feature.tags,
|
||||
locales = I18n.locales.get();
|
||||
|
||||
for (var i = 0; i < locales.length; i++) {
|
||||
if (tags["name:" + locales[i]]) {
|
||||
return tags["name:" + locales[i]];
|
||||
}
|
||||
}
|
||||
|
||||
if (tags["name"]) {
|
||||
return tags["name"];
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue