DEV: Enhance post action handler events (#23027)

This commit is contained in:
Angus McLeod
2023-08-09 19:55:00 +02:00
committed by GitHub
parent 993ed10cf0
commit 6801cf34cc
4 changed files with 55 additions and 2 deletions

View File

@ -279,9 +279,9 @@ class PostActionCreator
if post_action
case @post_action_type_id
when *PostActionType.notify_flag_type_ids
DiscourseEvent.trigger(:flag_created, post_action)
DiscourseEvent.trigger(:flag_created, post_action, self)
when PostActionType.types[:like]
DiscourseEvent.trigger(:like_created, post_action)
DiscourseEvent.trigger(:like_created, post_action, self)
end
end