app/jobs/sentry/send_event_job.rb in sentry-rails-4.8.1 vs app/jobs/sentry/send_event_job.rb in sentry-rails-4.8.2
- old
+ new
@@ -14,11 +14,11 @@
# this will prevent infinite loop when there's an issue deserializing SentryJob
if respond_to?(:discard_on)
discard_on ActiveJob::DeserializationError
else
# mimic what discard_on does for Rails 5.0
- rescue_from ActiveJob::DeserializationError do
- logger.error "Discarded #{self.class} due to a #{exception}. The original exception was #{error.cause.inspect}."
+ rescue_from ActiveJob::DeserializationError do |exception|
+ logger.error "Discarded #{self.class} due to a #{exception}. The original exception was #{exception.cause.inspect}."
end
end
def perform(event, hint = {})
Sentry.send_event(event, hint)