Sha256: 1759d7c142362a5470ad21305f1023195ef0b5357fc487a107f715f656223187

Contents?: true

Size: 336 Bytes

Versions: 4

Compression:

Stored size: 336 Bytes

Contents

# frozen_string_literal: true

module Dry
  module Transaction
    class StepAdapters
      # @api private
      class Tee
        include Dry::Monads::Result::Mixin

        def call(operation, _options, args)
          operation.(*args)
          Success(args[0])
        end
      end

      register :tee, Tee.new
    end
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
dry-transaction-0.14.0 lib/dry/transaction/step_adapters/tee.rb
dry-transaction-0.13.3 lib/dry/transaction/step_adapters/tee.rb
dry-transaction-0.13.2 lib/dry/transaction/step_adapters/tee.rb
dry-transaction-0.13.1 lib/dry/transaction/step_adapters/tee.rb