mirror of
https://github.com/codeninjasllc/discourse.git
synced 2024-11-30 10:58:31 -05:00
Add topic status_update change event
This commit is contained in:
parent
c3a393a11f
commit
770d38d025
1 changed files with 1 additions and 0 deletions
|
@ -433,6 +433,7 @@ class Topic < ActiveRecord::Base
|
||||||
|
|
||||||
def update_status(status, enabled, user, opts={})
|
def update_status(status, enabled, user, opts={})
|
||||||
TopicStatusUpdate.new(self, user).update!(status, enabled, opts)
|
TopicStatusUpdate.new(self, user).update!(status, enabled, opts)
|
||||||
|
DiscourseEvent.trigger(:topic_status_updated, self.id, status, enabled)
|
||||||
end
|
end
|
||||||
|
|
||||||
# Atomically creates the next post number
|
# Atomically creates the next post number
|
||||||
|
|
Loading…
Reference in a new issue