Permalink
Browse files

Right.

  • Loading branch information...
Yehuda Katz Yehuda Katz
Yehuda Katz authored and Yehuda Katz committed Feb 14, 2010
1 parent 98a5bf8 commit 38eb2f145432429d866ab62f796dd7055d1c524a
Showing with 4 additions and 1 deletion.
  1. +4 −1 activesupport/lib/active_support/dependencies.rb
@@ -177,7 +177,10 @@ def require_or_load(file_name)
end
def require_dependency(file_name, message = "No such file to load -- %s")
- raise ArgumentError, "the file name must be a String -- you passed #{file_name.inspect}"
+ unless file_name.is_a?(String)
+ raise ArgumentError, "the file name must be a String -- you passed #{file_name.inspect}"
+ end
+
Dependencies.depend_on(file_name, false, message)
end

0 comments on commit 38eb2f1

Please sign in to comment.