diff options
Diffstat (limited to 'railties/lib/initializer.rb')
-rw-r--r-- | railties/lib/initializer.rb | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/railties/lib/initializer.rb b/railties/lib/initializer.rb index 2d72b55b8b..350930bb15 100644 --- a/railties/lib/initializer.rb +++ b/railties/lib/initializer.rb @@ -146,7 +146,11 @@ module Rails def load_environment silence_warnings do config = configuration + constants = self.class.constants eval(IO.read(configuration.environment_path), binding) + (self.class.constants - constants).each do |const| + Object.const_set(const, self.class.const_get(const)) + end end end |