Class: ConvenientService::Service::Plugins::CollectsServicesInException::Middleware Private
- Inherits:
-
MethodChainMiddleware
- Object
- ConvenientService::Service::Plugins::CollectsServicesInException::Middleware
- Defined in:
- lib/convenient_service/service/plugins/collects_services_in_exception/middleware.rb
Overview
This class is part of a private API. You should avoid using this class if possible, as it may be removed or be changed in the future.
Instance Method Summary collapse
- #next ⇒ Object private
Instance Method Details
#next ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
29 30 31 32 33 34 35 36 37 |
# File 'lib/convenient_service/service/plugins/collects_services_in_exception/middleware.rb', line 29 def next(...) chain.next(...) rescue => exception exception.instance_exec { define_singleton_method(:services) { @services ||= [] } } unless exception.respond_to?(:services) Utils::Array.limited_push(exception.services, service_details, limit: max_services_size) raise end |