]> git.openstreetmap.org Git - rails.git/blobdiff - app/models/note_comment.rb
Rubocop fixes for ruby 2.5
[rails.git] / app / models / note_comment.rb
index f8450d0a369625be13158760ae3ae5eb70ec5635..f94032e1e3e785a398b6e5f1d06afe195f06d331 100644 (file)
@@ -33,7 +33,7 @@ class NoteComment < ActiveRecord::Base
   validates :visible, :inclusion => [true, false]
   validates :author, :associated => true
   validates :event, :inclusion => %w[opened closed reopened commented hidden]
-  validates :body, :format => /\A[^\x00-\x08\x0b-\x0c\x0e-\x1f\x7f\ufffe\uffff]*\z/
+  validates :body, :length => { :maximum => 2000 }, :characters => true
 
   # Return the comment text
   def body