FIX: `Warning` table has been renamed.

This commit is contained in:
Guo Xiang Tan 2017-04-15 13:07:47 +08:00
parent 89962793d0
commit 4327ebe2c3
1 changed files with 1 additions and 1 deletions

View File

@ -151,7 +151,7 @@ after_initialize do
mount ::DiscourseStaffNotes::Engine, at: "/staff_notes"
end
add_model_callback :warning, :after_create do
add_model_callback :user_warning, :after_create do
user = User.find_by_id(self.user_id)
created_by_user = User.find_by_id(self.created_by_id)
warning_topic = Topic.find_by_id(self.topic_id)