]> git.openstreetmap.org Git - rails.git/blobdiff - app/models/note_comment.rb
Merge remote-tracking branch 'upstream/pull/4779'
[rails.git] / app / models / note_comment.rb
index 999d045075f2f033bfc2a4e0ab9e8d83b296000a..b870e5558e557b2f2c337586206daf5ac6b8c356 100644 (file)
 #
 # Indexes
 #
-#  index_note_comments_on_body        (to_tsvector('english'::regconfig, body)) USING gin
-#  index_note_comments_on_created_at  (created_at)
-#  note_comments_note_id_idx          (note_id)
+#  index_note_comments_on_author_id_and_created_at  (author_id,created_at)
+#  index_note_comments_on_body                      (to_tsvector('english'::regconfig, body)) USING gin
+#  index_note_comments_on_created_at                (created_at)
+#  note_comments_note_id_idx                        (note_id)
 #
 # Foreign Keys
 #
@@ -29,7 +30,7 @@ class NoteComment < ApplicationRecord
 
   validates :id, :uniqueness => true, :presence => { :on => :update },
                  :numericality => { :on => :update, :only_integer => true }
-  validates :note, :presence => true, :associated => true
+  validates :note, :associated => true
   validates :visible, :inclusion => [true, false]
   validates :author, :associated => true
   validates :event, :inclusion => %w[opened closed reopened commented hidden]