From 445f89ccb57040e42355e2078d13f4b70a95ee7c Mon Sep 17 00:00:00 2001 From: David Heinemeier Hansson Date: Mon, 10 Jan 2005 23:52:37 +0000 Subject: Fixed that Dependencies.reload can't load the same file twice #420 [Kent Sibilev] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@377 5ecf4fe2-1ee6-0310-87b1-e25e094e27de --- activesupport/CHANGELOG | 2 ++ activesupport/lib/dependencies.rb | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/activesupport/CHANGELOG b/activesupport/CHANGELOG index 6ac105bde1..f379aae5b9 100644 --- a/activesupport/CHANGELOG +++ b/activesupport/CHANGELOG @@ -1,3 +1,5 @@ +* Fixed that Dependencies.reload can't load the same file twice #420 [Kent Sibilev] + * Added Fixnum#ago/until, Fixnum#since/from_now #450 [bitsweat] * Added that Inflector now accepts Symbols and Classes by calling .to_s on the word supplied diff --git a/activesupport/lib/dependencies.rb b/activesupport/lib/dependencies.rb index 1035bf714d..dc6c852c12 100644 --- a/activesupport/lib/dependencies.rb +++ b/activesupport/lib/dependencies.rb @@ -31,7 +31,7 @@ module Dependencies old_loaded.each do |file_name| begin - silence_warnings { load("#{file_name}.rb") } + silence_warnings { load("#{file_name}.rb") } unless loaded.include?(file_name) rescue LoadError # The association didn't reside in its own file, so we assume it was required by other means end -- cgit v1.2.3