Class: ConvenientService::Common::Plugins::TriesToConvertResultDuckToResult::Middleware Private
- Inherits:
-
MethodChainMiddleware
- Object
- ConvenientService::Common::Plugins::TriesToConvertResultDuckToResult::Middleware
- Defined in:
- lib/convenient_service/common/plugins/tries_to_convert_result_duck_to_result/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
Instance Method Details
#next ⇒ ConvenientService::Service::Plugins::HasJSendResult::Entities::Result
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.
26 27 28 29 30 31 32 |
# File 'lib/convenient_service/common/plugins/tries_to_convert_result_duck_to_result/middleware.rb', line 26 def next(...) original_object = chain.next(...) result_duck, result = try_convert(original_object) result_duck ? result : original_object end |