X-Git-Url: https://git.openstreetmap.org./rails.git/blobdiff_plain/c24c2e481cc6d27e76274ed4e32668a4690a7788..c8e21c409c9bec446f0caa2526d5b07861bb3299:/app/helpers/browse_helper.rb?ds=inline diff --git a/app/helpers/browse_helper.rb b/app/helpers/browse_helper.rb index cf2bc6474..1e9465f80 100644 --- a/app/helpers/browse_helper.rb +++ b/app/helpers/browse_helper.rb @@ -13,7 +13,7 @@ module BrowseHelper unless object.redacted? available_locales = Locale.list(name_locales(object)) - locale = available_locales.preferred(preferred_languages) + locale = available_locales.preferred(preferred_languages, :default => nil) if object.tags.include? "name:#{locale}" name = t "printable_name.with_name_html", :name => tag.bdi(object.tags["name:#{locale}"].to_s), :id => tag.bdi(name) @@ -44,7 +44,7 @@ module BrowseHelper if object.redacted? "" else - h(icon_tags(object).map { |k, v| k + "=" + v }.to_sentence) + h(icon_tags(object).map { |k, v| "#{k}=#{v}" }.to_sentence) end end