Sha256: a36af82905d7905730da7d03e33a2181adfedb781fbfb1d5b7e6532af08f16fb

Contents?: true

Size: 840 Bytes

Versions: 14

Compression:

Stored size: 840 Bytes

Contents

module Hyrax
  module Actors
    # Used to wrap the stack in a database transaction.
    # This would have rolled back any database actions (particularly workflow) if there
    # is an error elsewhere in the actor stack.
    # This was problematic, is removed in v3.0, and is currently a no-op
    # Backport of https://github.com/samvera/hyrax/pull/3482
    class TransactionalRequest < Actors::AbstractActor
      # rubocop:disable Rails/Delegate
      # @param [Hyrax::Actors::Environment] env
      # @return [Boolean] true if create was successful
      def create(env)
        next_actor.create(env)
      end

      # @param [Hyrax::Actors::Environment] env
      # @return [Boolean] true if update was successful
      def update(env)
        next_actor.update(env)
      end
      # rubocop:enable Rails/Delegate
    end
  end
end

Version data entries

14 entries across 14 versions & 1 rubygems

Version Path
hyrax-2.9.6 app/actors/hyrax/actors/transactional_request.rb
hyrax-2.9.5 app/actors/hyrax/actors/transactional_request.rb
hyrax-2.9.4 app/actors/hyrax/actors/transactional_request.rb
hyrax-2.9.3 app/actors/hyrax/actors/transactional_request.rb
hyrax-2.9.2 app/actors/hyrax/actors/transactional_request.rb
hyrax-2.9.1 app/actors/hyrax/actors/transactional_request.rb
hyrax-2.9.0 app/actors/hyrax/actors/transactional_request.rb
hyrax-2.8.0 app/actors/hyrax/actors/transactional_request.rb
hyrax-2.7.2 app/actors/hyrax/actors/transactional_request.rb
hyrax-2.7.1 app/actors/hyrax/actors/transactional_request.rb
hyrax-2.7.0 app/actors/hyrax/actors/transactional_request.rb
hyrax-2.6.0 app/actors/hyrax/actors/transactional_request.rb
hyrax-2.5.1 app/actors/hyrax/actors/transactional_request.rb
hyrax-2.5.0 app/actors/hyrax/actors/transactional_request.rb