Skip to content

Commit

Permalink
Tidying up some require : removing useless sort and homogenizing with…
Browse files Browse the repository at this point in the history
… the rest of the code the wat the includes are done
  • Loading branch information
Intrepidd committed Mar 20, 2013
1 parent acb78c2 commit 9c025ab
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 6 deletions.
5 changes: 1 addition & 4 deletions activemodel/lib/active_model/validations.rb
Original file line number Diff line number Diff line change
Expand Up @@ -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 }
4 changes: 2 additions & 2 deletions activesupport/lib/active_support/core_ext.rb
Original file line number Diff line number Diff line change
@@ -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.