Skip to content

Commit

Permalink
CurationConcern.actor_factory does not need to be settable. Fixes #1398
Browse files Browse the repository at this point in the history
  • Loading branch information
jcoyne committed Aug 1, 2017
1 parent 860cf88 commit dd8d1ed
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 6 deletions.
6 changes: 4 additions & 2 deletions app/services/hyrax/curation_concern.rb
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,10 @@ class CurationConcern
#
# You can customize the actor stack, so long as you do so before the actor
# is used. Once it is used, it becomes immutable.
# This attribute is set by Hyrax::Engine
class_attribute :actor_factory
# @return [ActionDispatch::MiddlewareStack]
def self.actor_factory
Hyrax::DefaultMiddlewareStack.build_stack
end

# A consumer of this method can inject a different factory
# into this class in order to change the behavior of this method.
Expand Down
4 changes: 0 additions & 4 deletions lib/hyrax/engine.rb
Original file line number Diff line number Diff line change
Expand Up @@ -37,10 +37,6 @@ class Engine < ::Rails::Engine
end
end

config.to_prepare do
Hyrax::CurationConcern.actor_factory = Hyrax::DefaultMiddlewareStack.build_stack
end

initializer 'requires' do
require 'hydra/derivatives'
require 'hyrax/controller_resource'
Expand Down

0 comments on commit dd8d1ed

Please sign in to comment.