mirror of
https://github.com/discourse/discourse.git
synced 2024-11-23 16:46:12 +08:00
FIX: pending flags reminder email was ignoring the 'notify about flags after' site setting.
This commit is contained in:
parent
6fc2d9db3a
commit
06c9e79984
|
@ -9,7 +9,7 @@ module Jobs
|
|||
def execute(args)
|
||||
if SiteSetting.notify_about_flags_after > 0 &&
|
||||
PostAction.flagged_posts_count > 0 &&
|
||||
FlagQuery.flagged_post_actions('active').where('post_actions.created_at < ?', 48.hours.ago).pluck(:id).count > 0
|
||||
FlagQuery.flagged_post_actions('active').where('post_actions.created_at < ?', SiteSetting.notify_about_flags_after.to_i.hours.ago).pluck(:id).count > 0
|
||||
|
||||
message = PendingFlagsMailer.notify
|
||||
Email::Sender.new(message, :pending_flags_reminder).send
|
||||
|
|
Loading…
Reference in New Issue
Block a user