]> git.openstreetmap.org Git - rails.git/blobdiff - app/models/tracetag.rb
Added tests for validators
[rails.git] / app / models / tracetag.rb
index 1a4fbd39889195a4653fcc1ed9fec5be3d8e4126..0a59ba29abb1dcbe9fbf856437298034a38b5e12 100644 (file)
@@ -22,5 +22,5 @@ class Tracetag < ActiveRecord::Base
   belongs_to :trace, :foreign_key => "gpx_id"
 
   validates :trace, :associated => true
-  validates :tag, :length => 1..255, :format => %r{\A[^/;.,?]*\z}
+  validates :tag, :length => 1..255, :format => %r{\A[^/;.,?]*\z}, :invalid_chars => true
 end