Class: Hermes::DatabaseErrorHandler
- Inherits:
-
Object
- Object
- Hermes::DatabaseErrorHandler
- Defined in:
- lib/hermes/database_error_handler.rb
Instance Method Summary collapse
- #call(error) ⇒ Object
-
#initialize(error_notification_service:) ⇒ DatabaseErrorHandler
constructor
A new instance of DatabaseErrorHandler.
Constructor Details
#initialize(error_notification_service:) ⇒ DatabaseErrorHandler
Returns a new instance of DatabaseErrorHandler.
6 7 8 |
# File 'lib/hermes/database_error_handler.rb', line 6 def initialize(error_notification_service:) @error_notification_service = error_notification_service end |
Instance Method Details
#call(error) ⇒ Object
10 11 12 |
# File 'lib/hermes/database_error_handler.rb', line 10 def call(error) error_notification_service.capture_exception(error) end |