diff options
author | Yves Senn <yves.senn@gmail.com> | 2012-11-25 17:08:57 +0100 |
---|---|---|
committer | Yves Senn <yves.senn@gmail.com> | 2012-11-25 17:08:57 +0100 |
commit | 22598ee5992fc81d200b3aa99f18248a5259161a (patch) | |
tree | 2f7442bc3d63f7027c791f942ae88cebd49005f6 | |
parent | b7edbc718b2d1c6cc02b337283633ea4c05795ca (diff) | |
download | rails-22598ee5992fc81d200b3aa99f18248a5259161a.tar.gz rails-22598ee5992fc81d200b3aa99f18248a5259161a.tar.bz2 rails-22598ee5992fc81d200b3aa99f18248a5259161a.zip |
cleanup, removed dispensable `require` statements from `ActiveModel`
-rw-r--r-- | activemodel/CHANGELOG.md | 5 | ||||
-rw-r--r-- | activemodel/lib/active_model/callbacks.rb | 2 | ||||
-rw-r--r-- | activemodel/lib/active_model/conversion.rb | 2 | ||||
-rw-r--r-- | activemodel/lib/active_model/dirty.rb | 1 | ||||
-rw-r--r-- | activemodel/lib/active_model/naming.rb | 1 | ||||
-rw-r--r-- | activemodel/lib/active_model/observing.rb | 1 | ||||
-rw-r--r-- | activemodel/lib/active_model/validations.rb | 3 | ||||
-rw-r--r-- | activemodel/lib/active_model/validations/callbacks.rb | 2 |
8 files changed, 5 insertions, 12 deletions
diff --git a/activemodel/CHANGELOG.md b/activemodel/CHANGELOG.md index 133bb558a9..5c41da246f 100644 --- a/activemodel/CHANGELOG.md +++ b/activemodel/CHANGELOG.md @@ -1,5 +1,10 @@ ## Rails 4.0.0 (unreleased) ## +* Removed dispensable `require` statements. Make sure to require `active_model` before requiring + individual parts of the framework. + + *Yves Senn* + * Use BCrypt's MIN_COST in the test environment for speedier tests when using `has_secure_pasword`. *Brian Cardarella + Jeremy Kemper + Trevor Turk* diff --git a/activemodel/lib/active_model/callbacks.rb b/activemodel/lib/active_model/callbacks.rb index eab94554cc..c52e4947ae 100644 --- a/activemodel/lib/active_model/callbacks.rb +++ b/activemodel/lib/active_model/callbacks.rb @@ -1,5 +1,3 @@ -require 'active_support/callbacks' - module ActiveModel # == Active \Model \Callbacks # diff --git a/activemodel/lib/active_model/conversion.rb b/activemodel/lib/active_model/conversion.rb index 42de32e63e..1f5d23dd8e 100644 --- a/activemodel/lib/active_model/conversion.rb +++ b/activemodel/lib/active_model/conversion.rb @@ -1,5 +1,3 @@ -require 'active_support/inflector' - module ActiveModel # == Active \Model Conversions # diff --git a/activemodel/lib/active_model/dirty.rb b/activemodel/lib/active_model/dirty.rb index 9d09353ef2..d47c3ae1bb 100644 --- a/activemodel/lib/active_model/dirty.rb +++ b/activemodel/lib/active_model/dirty.rb @@ -1,4 +1,3 @@ -require 'active_model/attribute_methods' require 'active_support/hash_with_indifferent_access' require 'active_support/core_ext/object/duplicable' diff --git a/activemodel/lib/active_model/naming.rb b/activemodel/lib/active_model/naming.rb index b9297db108..6887f6d781 100644 --- a/activemodel/lib/active_model/naming.rb +++ b/activemodel/lib/active_model/naming.rb @@ -1,4 +1,3 @@ -require 'active_support/inflector' require 'active_support/core_ext/hash/except' require 'active_support/core_ext/module/introspection' diff --git a/activemodel/lib/active_model/observing.rb b/activemodel/lib/active_model/observing.rb index 26518c047b..b4e40bada4 100644 --- a/activemodel/lib/active_model/observing.rb +++ b/activemodel/lib/active_model/observing.rb @@ -5,7 +5,6 @@ require 'active_support/core_ext/module/remove_method' require 'active_support/core_ext/string/inflections' require 'active_support/core_ext/enumerable' require 'active_support/core_ext/object/try' -require 'active_support/descendants_tracker' module ActiveModel # == Active \Model Observers Activation diff --git a/activemodel/lib/active_model/validations.rb b/activemodel/lib/active_model/validations.rb index 2524b8d065..2db4a25f61 100644 --- a/activemodel/lib/active_model/validations.rb +++ b/activemodel/lib/active_model/validations.rb @@ -1,9 +1,6 @@ require 'active_support/core_ext/array/extract_options' require 'active_support/core_ext/hash/keys' require 'active_support/core_ext/hash/except' -require 'active_model/errors' -require 'active_model/validations/callbacks' -require 'active_model/validator' module ActiveModel diff --git a/activemodel/lib/active_model/validations/callbacks.rb b/activemodel/lib/active_model/validations/callbacks.rb index 5cb6abaf9f..e28ad2841b 100644 --- a/activemodel/lib/active_model/validations/callbacks.rb +++ b/activemodel/lib/active_model/validations/callbacks.rb @@ -1,5 +1,3 @@ -require 'active_support/callbacks' - module ActiveModel module Validations # == Active \Model Validation Callbacks |