Exception: Metasploit::Concern::Error::EagerLoad
- Defined in:
- lib/metasploit/concern/error/eager_load.rb
Overview
Exception raised when a ‘Rails::Engine` has left its `’app/concerns’‘ path as `eager_load: true`
Instance Method Summary collapse
-
#initialize(engine) ⇒ EagerLoad
constructor
A new instance of EagerLoad.
Constructor Details
#initialize(engine) ⇒ EagerLoad
Returns a new instance of EagerLoad.
4 5 6 7 8 9 10 11 12 13 14 15 16 |
# File 'lib/metasploit/concern/error/eager_load.rb', line 4 def initialize(engine) @engine = engine engine_name = engine.class.name super( "#{engine_name}'s `app/concerns` is marked as `eager_load: true`. This will cause circular dependency " \ "errors when the concerns are loaded. Declare `app/concerns` to stop it from inheriting `eager_load: true` " \ "from `app`: \n" \ "\n" \ " class #{engine_name} < Rails::Engine\n" \ " config.paths.add 'app/concerns', autoload: true\n" \ " end\n" ) end |