diff options
author | Rafael Mendonça França <rafaelmfranca@gmail.com> | 2015-03-29 23:57:49 -0300 |
---|---|---|
committer | Andrew White <andyw@pixeltrix.co.uk> | 2015-04-22 15:11:21 -0400 |
commit | 8d901b905c33c22c745fa72fa81e3bd35e56dce4 (patch) | |
tree | c34f0c4537ac95b31c4f51ae2af62a870c985bd0 | |
parent | 688c0ec26454c9ab64d8d11fc689a3fe9ab5924f (diff) | |
download | rails-8d901b905c33c22c745fa72fa81e3bd35e56dce4.tar.gz rails-8d901b905c33c22c745fa72fa81e3bd35e56dce4.tar.bz2 rails-8d901b905c33c22c745fa72fa81e3bd35e56dce4.zip |
Require yaml before trying to rescue its exception class
-rw-r--r-- | railties/lib/rails/application.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/railties/lib/rails/application.rb b/railties/lib/rails/application.rb index 3e3ef72742..a65f8f2ad9 100644 --- a/railties/lib/rails/application.rb +++ b/railties/lib/rails/application.rb @@ -1,4 +1,5 @@ require 'fileutils' +require 'yaml' require 'active_support/core_ext/hash/keys' require 'active_support/core_ext/object/blank' require 'active_support/key_generator' @@ -228,7 +229,6 @@ module Rails yaml = Pathname.new("#{paths["config"].existent.first}/#{name}.yml") if yaml.exist? - require "yaml" require "erb" (YAML.load(ERB.new(yaml.read).result) || {})[Rails.env] || {} else |