aboutsummaryrefslogtreecommitdiffstats
path: root/railties/lib/rails/engine.rb
diff options
context:
space:
mode:
authorYves Senn <yves.senn@gmail.com>2013-11-11 23:36:02 -0800
committerYves Senn <yves.senn@gmail.com>2013-11-11 23:36:02 -0800
commit98991a98398feae3988be72563c80f808a74ebeb (patch)
treece1a8f741855a3d7e0499a5f14637c0838561667 /railties/lib/rails/engine.rb
parentbd004eccfa1b7e6c8e4f1273da94477d75b9515f (diff)
parentec3134739c6bf7cf6482feb46155293e2b09c45b (diff)
downloadrails-98991a98398feae3988be72563c80f808a74ebeb.tar.gz
rails-98991a98398feae3988be72563c80f808a74ebeb.tar.bz2
rails-98991a98398feae3988be72563c80f808a74ebeb.zip
Merge pull request #12695 from mikepack/allow_pathnames
Allow Pathnames to be added to eager load paths
Diffstat (limited to 'railties/lib/rails/engine.rb')
-rw-r--r--railties/lib/rails/engine.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/railties/lib/rails/engine.rb b/railties/lib/rails/engine.rb
index e8adef2fd3..1296c0a843 100644
--- a/railties/lib/rails/engine.rb
+++ b/railties/lib/rails/engine.rb
@@ -465,7 +465,7 @@ module Rails
# files inside eager_load paths.
def eager_load!
config.eager_load_paths.each do |load_path|
- matcher = /\A#{Regexp.escape(load_path)}\/(.*)\.rb\Z/
+ matcher = /\A#{Regexp.escape(load_path.to_s)}\/(.*)\.rb\Z/
Dir.glob("#{load_path}/**/*.rb").sort.each do |file|
require_dependency file.sub(matcher, '\1')
end