Skip to content

Commit

Permalink
Add logging when we're about to send a failure email (#18704)
Browse files Browse the repository at this point in the history
  • Loading branch information
Thrillberg authored Oct 5, 2024
1 parent 56f3840 commit 0d165aa
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions app/models/form_submission_attempt.rb
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,12 @@ class FormSubmissionAttempt < ApplicationRecord

event :fail do
after do
Rails.logger.info({
message: 'Preparing to send Form Submission Attempt error email',
form_submission_id:,
benefits_intake_uuid: form_submission&.benefits_intake_uuid,
form_type: form_submission&.form_type
})
enqueue_result_email(:error) if Flipper.enabled?(:simple_forms_email_notifications)
end

Expand Down

0 comments on commit 0d165aa

Please sign in to comment.