Sha256: b2c37f587cd3bec10291ec91a9ccacd071662d20c69484646106247b12212ebc

Contents?: true

Size: 460 Bytes

Versions: 10

Compression:

Stored size: 460 Bytes

Contents

# frozen_string_literal: true

module Micro
  module Cases
    module Safe
      class Flow < Cases::Flow
        private def __call_use_case(use_case, result, input)
          instance = __build_use_case(use_case, result, input)
          instance.__call__
        rescue => exception
          raise exception if Case::Error.by_wrong_usage?(exception)

          result.__set__(false, exception, :exception, instance)
        end
      end
    end
  end
end

Version data entries

10 entries across 10 versions & 1 rubygems

Version Path
u-case-4.5.2 lib/micro/cases/safe/flow.rb
u-case-4.5.1 lib/micro/cases/safe/flow.rb
u-case-4.5.0 lib/micro/cases/safe/flow.rb
u-case-4.4.0 lib/micro/cases/safe/flow.rb
u-case-4.3.0 lib/micro/cases/safe/flow.rb
u-case-4.2.2 lib/micro/cases/safe/flow.rb
u-case-4.2.1 lib/micro/cases/safe/flow.rb
u-case-4.2.0 lib/micro/cases/safe/flow.rb
u-case-4.1.1 lib/micro/cases/safe/flow.rb
u-case-4.1.0 lib/micro/cases/safe/flow.rb