Files
openfoodnetwork/lib/open_food_network/error_logger.rb
Maikel Linke 9dcc683dc0 Notify Bugsnag on sign-up errors
This may lead to more error reports than we want to see. A not existing
email address may cause Bugsnag to be notified. If this happens, we can
rescue form these specific errors and only report the rest.
2018-09-27 13:33:09 +10:00

14 lines
417 B
Ruby

# Our error logging API currently wraps Bugsnag.
# It makes us more flexible if we wanted to replace Bugsnag or change logging
# behaviour.
module OpenFoodNetwork
module ErrorLogger
# Tries to escalate the error to a developer.
# If Bugsnag is configured, it will notify it. It would be nice to implement
# some kind of fallback.
def self.notify(error)
Bugsnag.notify(error)
end
end
end