Skip to content

Commit

Permalink
Merge pull request #6144 from samvera/no-init-workflow-actor
Browse files Browse the repository at this point in the history
remove fallback behavior for dropped InitializeWorkflowActor
  • Loading branch information
tpendragon authored Aug 22, 2023
2 parents cbe9278 + 249d444 commit 9d06f2b
Showing 1 changed file with 8 additions and 11 deletions.
19 changes: 8 additions & 11 deletions app/services/hyrax/listeners/workflow_listener.rb
Original file line number Diff line number Diff line change
Expand Up @@ -7,17 +7,14 @@ module Listeners
# manages workflow accordingly.
class WorkflowListener
##
# @note respects class attribute configuration at
# {Hyrax::Actors::InitializeWorkflowActor.workflow_factory}, but falls
# back on {Hyrax::Workflow::WorkflowFactory} to prepare for removal of
# Actors
# @return [#create] default: {Hyrax::Workflow::WorkflowFactory}
def factory
if defined?(Hyrax::Actors::InitializeWorkflowActor)
Hyrax::Actors::InitializeWorkflowActor.workflow_factory
else
Hyrax::Workflow::WorkflowFactory
end
# @!attribute [rw] factory
# @return [#create]
attr_accessor :factory

##
# @param [#create] factory
def initialize(factory: Hyrax::Workflow::WorkflowFactory)
@factory = factory
end

##
Expand Down

0 comments on commit 9d06f2b

Please sign in to comment.