lib/tobox/plugins/sentry.rb in tobox-0.3.1 vs lib/tobox/plugins/sentry.rb in tobox-0.3.2

- old
+ new

@@ -107,10 +107,12 @@ store.delete(event[:id]) end def capture_exception(event, error) - return unless ::Sentry.configuration.tobox.report_after_retries && event[:attempts] >= @max_attempts + if ::Sentry.configuration.tobox.report_after_retries && event[:attempts] && event[:attempts] < @max_attempts + return + end ::Sentry.capture_exception( error, hint: { background: false } )