FIX: pending flags reminder email was ignoring the 'notify about flags after' site setting.
This commit is contained in:
parent
6fc2d9db3a
commit
06c9e79984
1 changed files with 1 additions and 1 deletions
|
@ -9,7 +9,7 @@ module Jobs
|
||||||
def execute(args)
|
def execute(args)
|
||||||
if SiteSetting.notify_about_flags_after > 0 &&
|
if SiteSetting.notify_about_flags_after > 0 &&
|
||||||
PostAction.flagged_posts_count > 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
|
message = PendingFlagsMailer.notify
|
||||||
Email::Sender.new(message, :pending_flags_reminder).send
|
Email::Sender.new(message, :pending_flags_reminder).send
|
||||||
|
|
Reference in a new issue