Class: ConvenientService::Service::Plugins::CanHaveSteps::Entities::Step::Plugins::RaisesOnNotResultReturnValue::Middleware
- Inherits:
-
MethodChainMiddleware
- Object
- ConvenientService::Service::Plugins::CanHaveSteps::Entities::Step::Plugins::RaisesOnNotResultReturnValue::Middleware
- Defined in:
- lib/convenient_service/service/plugins/can_have_steps/entities/step/plugins/raises_on_not_result_return_value/middleware.rb
Instance Method Summary collapse
Methods included from ConvenientService::Support::DependencyContainer::Import
Instance Method Details
#next ⇒ Object
18 19 20 21 22 23 24 |
# File 'lib/convenient_service/service/plugins/can_have_steps/entities/step/plugins/raises_on_not_result_return_value/middleware.rb', line 18 def next(...) original_result = chain.next(...) return original_result if commands.is_result?(original_result) ::ConvenientService.raise Exceptions::ReturnValueNotKindOfResult.new(step: entity, result: original_result) end |