diff options
Diffstat (limited to 'activesupport/lib/dependencies.rb')
-rw-r--r-- | activesupport/lib/dependencies.rb | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/activesupport/lib/dependencies.rb b/activesupport/lib/dependencies.rb index 93c40fed1c..1452b63a77 100644 --- a/activesupport/lib/dependencies.rb +++ b/activesupport/lib/dependencies.rb @@ -30,8 +30,10 @@ module Dependencies clear old_loaded.each do |file_name| + next if loaded.include?(file_name) + begin - silence_warnings { load("#{file_name}.rb") } unless loaded.include?(file_name) + silence_warnings { load("#{file_name}.rb") } loaded << file_name rescue LoadError # The association didn't reside in its own file, so we assume it was required by other means |