X-Git-Url: https://git.openstreetmap.org./rails.git/blobdiff_plain/4347d9d3b00a8fffe78daa93eac5b490905f9ac8..e4c40cbd36567d050f1b779f1444c4ef26c50a5b:/app/models/trace.rb diff --git a/app/models/trace.rb b/app/models/trace.rb index 0860d2b31..b3d87fc09 100644 --- a/app/models/trace.rb +++ b/app/models/trace.rb @@ -53,7 +53,7 @@ class Trace < ApplicationRecord def tagstring=(s) self.tags = if s.include? "," - s.split(/\s*,\s*/).reject { |tag| tag =~ /^\s*$/ }.collect do |tag| + s.split(/\s*,\s*/).grep_v(/^\s*$/).collect do |tag| tt = Tracetag.new tt.tag = tag tt