lib/lotus/commands/console.rb in lotusrb-0.4.0 vs lib/lotus/commands/console.rb in lotusrb-0.4.1

- old
+ new

@@ -26,12 +26,12 @@ ARGV.shift until ARGV.empty? @environment.require_application_environment # Add convenience methods to the main:Object binding TOPLEVEL_BINDING.eval('self').send(:include, Methods) - Lotus::Application.preload_applications! + load_application engine.start end def engine load_engine options.fetch(:engine) { engine_lookup } @@ -54,9 +54,17 @@ return Object.const_get( ENGINES.fetch(engine) { raise ArgumentError.new("Unknown console engine: #{ engine }") } ) + end + + def load_application + if @environment.container? + Lotus::Container.new + else + Lotus::Application.preload_applications! + end end end end end