Class: ConvenientService::Service::Plugins::CanHaveRollbacks::Middleware

Inherits:
MethodChainMiddleware
  • Object
show all
Defined in:
lib/convenient_service/service/plugins/can_have_rollbacks/middleware.rb

Instance Method Summary collapse

Instance Method Details

#nextConvenientService::Service::Plugins::HasJSendResult::Entities::Result



13
14
15
16
17
18
19
# File 'lib/convenient_service/service/plugins/can_have_rollbacks/middleware.rb', line 13

def next(...)
  result = chain.next(...)

  rollback_result(result) if result.status.unsafe_not_success?

  result
end