lib/trestle/engine.rb in trestle-0.9.3 vs lib/trestle/engine.rb in trestle-0.9.4
- old
+ new
@@ -42,15 +42,12 @@
config.to_prepare do
Engine.reset_helpers!
end
- config.to_prepare do
- Engine.reloader.execute
- end
-
- def reloader
- @reloader ||= Trestle::Reloader.new
+ config.after_initialize do |app|
+ reloader = Trestle::Reloader.new(*app.watchable_args)
+ reloader.install(app) unless app.config.eager_load
end
def reset_helpers!
@helpers = nil
end