Permalink
Browse files

Tidying up some require : removing useless sort and homogenizing with…

… the rest of the code the wat the includes are done
  • Loading branch information...
1 parent acb78c2 commit 9c025ab6e9731dde56186b41ba5d4f216a48c831 @Intrepidd Intrepidd committed Mar 20, 2013
Showing with 3 additions and 6 deletions.
  1. +1 −4 activemodel/lib/active_model/validations.rb
  2. +2 −2 activesupport/lib/active_support/core_ext.rb
@@ -376,7 +376,4 @@ def run_validations! #:nodoc:
end
end
-Dir[File.dirname(__FILE__) + "/validations/*.rb"].sort.each do |path|
- filename = File.basename(path)
- require "active_model/validations/#{filename}"
-end
+Dir[File.dirname(__FILE__) + "/validations/*.rb"].each { |file| require file }
@@ -1,4 +1,4 @@
-Dir["#{File.dirname(__FILE__)}/core_ext/*.rb"].sort.each do |path|
+Dir["#{File.dirname(__FILE__)}/core_ext/*.rb"].each do |path|
next if File.basename(path, '.rb') == 'logger'
- require "active_support/core_ext/#{File.basename(path, '.rb')}"
+ require path
end

0 comments on commit 9c025ab

Please sign in to comment.