diff options
-rw-r--r-- | activesupport/lib/active_support/dependencies.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/activesupport/lib/active_support/dependencies.rb b/activesupport/lib/active_support/dependencies.rb index d2afea2545..45c9f0472a 100644 --- a/activesupport/lib/active_support/dependencies.rb +++ b/activesupport/lib/active_support/dependencies.rb @@ -481,7 +481,7 @@ module ActiveSupport #:nodoc: if file_path expanded = File.expand_path(file_path) - expanded.sub!(/\.rb/, '') + expanded.sub!(/\.rb\z/, '') if loaded.include?(expanded) raise "Circular dependency detected while autoloading constant #{qualified_name}" |