fix: Add email rate limiting to automation rule actions (#13474)
This commit is contained in:
@@ -58,7 +58,10 @@ class AutomationRules::ActionService < ActionService
|
||||
teams = Team.where(id: params[0][:team_ids])
|
||||
|
||||
teams.each do |team|
|
||||
break unless @account.within_email_rate_limit?
|
||||
|
||||
TeamNotifications::AutomationNotificationMailer.conversation_creation(@conversation, team, params[0][:message])&.deliver_now
|
||||
@account.increment_email_sent_count
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user