Ruby on Rails | Screencasts | Download | Documentation | Weblog | Community | Source

Changeset 1050

Show
Ignore:
Timestamp:
04/02/05 01:06:53 (3 years ago)
Author:
bitsweat
Message:

Don't establish db connection if no configuration is provided.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • tools/conductor/config/environment.rb

    r1027 r1050  
    3838require_dependency "environments/#{RAILS_ENV}" 
    3939ActiveRecord::Base.configurations = YAML::load(File.open("#{RAILS_ROOT}/config/database.yml")) 
    40 ActiveRecord::Base.establish_connection 
     40if ActiveRecord::Base.configurations[RAILS_ENV] 
     41  ActiveRecord::Base.establish_connection 
     42end 
    4143 
    4244