mirror of
https://github.com/discourse/discourse.git
synced 2025-02-25 18:55:32 -06:00
FIX: Sending a PM through a flag on a deleted post
Because we allow all the other flag types on a deleted post we should be able to send a pm to the user letting them know why we deleted their post. Bug report: https://meta.discourse.org/t/-/161156
This commit is contained in:
@@ -33,7 +33,7 @@ module PostGuardian
|
||||
return false if action_key == :notify_user && (post.user.blank? || (!is_staff? && opts[:is_warning].present? && opts[:is_warning] == 'true'))
|
||||
|
||||
taken = opts[:taken_actions].try(:keys).to_a
|
||||
is_flag = PostActionType.notify_flag_types[action_key]
|
||||
is_flag = PostActionType.notify_flag_types[action_key] || PostActionType.custom_types[action_key]
|
||||
already_taken_this_action = taken.any? && taken.include?(PostActionType.types[action_key])
|
||||
already_did_flagging = taken.any? && (taken & PostActionType.notify_flag_types.values).any?
|
||||
|
||||
|
||||
Reference in New Issue
Block a user