From: Tom Hughes Date: Sun, 13 Oct 2019 09:53:08 +0000 (+0100) Subject: Don't try and commas to the trace size X-Git-Tag: live~2521 X-Git-Url: https://git.openstreetmap.org/rails.git/commitdiff_plain/3b636ddb6f8f5f598311f74ccb92220ced27ec7f?hp=651342197aee57d94f30a517c8fa1d67ead6df66 Don't try and commas to the trace size It breaks pluralisation lookups in the locale and in any case adding a comma every three digits is locale specific. Fixes #2388 --- diff --git a/app/views/traces/_trace.html.erb b/app/views/traces/_trace.html.erb index ceeb4d88d..1fde78790 100644 --- a/app/views/traces/_trace.html.erb +++ b/app/views/traces/_trace.html.erb @@ -12,7 +12,7 @@ <%= link_to trace.name, :controller => "traces", :action => "show", :display_name => trace.user.display_name, :id => trace.id %> ... <% if trace.inserted %> - (<%= t ".count_points", :count => trace.size.to_s.gsub(/(\d)(?=(\d{3})+$)/, '\1,') %>) + (<%= t ".count_points", :count => trace.size %>) <% end %> ... <%= time_ago_in_words(trace.timestamp, :scope => :'datetime.distance_in_words_ago') %> <%= link_to_if trace.inserted?, t(".map"), { :controller => "site", :action => "index", :mlat => trace.latitude, :mlon => trace.longitude, :anchor => "map=14/#{trace.latitude}/#{trace.longitude}" }, { :title => t(".view_map") } %> /