From 3b015e0c22a198284416cee2289fe6b90f2770f2 Mon Sep 17 00:00:00 2001 From: f Date: Thu, 11 Feb 2021 11:26:17 -0300 Subject: [PATCH] excepciones con contexto closes #255 closes #256 closes #257 closes #258 closes #259 --- app/jobs/maintenance_job.rb | 2 +- app/models/metadata_template.rb | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/app/jobs/maintenance_job.rb b/app/jobs/maintenance_job.rb index 114ff77b..9d1eb7d0 100644 --- a/app/jobs/maintenance_job.rb +++ b/app/jobs/maintenance_job.rb @@ -29,7 +29,7 @@ class MaintenanceJob < ApplicationJob rescue Net::SMTPServerBusy => e # Algunas direcciones no son válidas, no queremos detener el # envío pero sí enterarnos cuáles son - ExceptionNotifier.notify_exception e + ExceptionNotifier.notify_exception(e, data: { maintenance_id: maintenance_id, email: u[0]) }) end end end diff --git a/app/models/metadata_template.rb b/app/models/metadata_template.rb index e7e2edb8..0d8669d1 100644 --- a/app/models/metadata_template.rb +++ b/app/models/metadata_template.rb @@ -172,7 +172,7 @@ MetadataTemplate = Struct.new(:site, :document, :name, :label, :type, box.decrypt_str value.to_s rescue Lockbox::DecryptionError => e - ExceptionNotifier.notify_exception(e) + ExceptionNotifier.notify_exception(e, data: { site: site.name, post: post.path.absolute, name: name }) I18n.t('lockbox.help.decryption_error') end