Commit 9f427757 by Your Name

Revert "fix merge conflict"

This reverts commit 5f90d8fd, reversing
changes made to 55cc9867.
parent 5f90d8fd
......@@ -32,7 +32,6 @@ class Comment < Content
belongs_to :comment_thread, index: true
belongs_to :author, class_name: "User", index: true
after_save :update_thread_index
attr_accessible :body, :course_id, :anonymous, :anonymous_to_peers, :endorsed
......@@ -116,10 +115,4 @@ private
self.comment_thread.update_attributes!(last_activity_at: Time.now.utc)
end
def update_thread_index
#after each save of a comment, update it's thread's search index
#t = self.comment_thread
tire.update_index
end
end
......@@ -50,7 +50,7 @@ class CommentThread < Content
end
belongs_to :author, class_name: "User", inverse_of: :comment_threads, index: true#, autosave: true
has_many :comments, dependent: :destroy #, autosave: true# Use destroy to envoke callback on the top-level comments TODO async
has_many :comments, dependent: :destroy#, autosave: true# Use destroy to envoke callback on the top-level comments TODO async
has_many :activities, autosave: true
attr_accessible :title, :body, :course_id, :commentable_id, :anonymous, :anonymous_to_peers, :closed
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment