Module: Mongoid::Config::DeprecatedOptions
Relationships & Source Files | |
Extension / Inclusion / Inheritance Descendants | |
Included In:
| |
Defined in: | lib/mongoid/config.rb |
Constant Summary
-
OPTIONS =
# File 'lib/mongoid/config.rb', line 428%i[]
Class Method Summary
Class Method Details
.prepended(klass)
[ GitHub ]# File 'lib/mongoid/config.rb', line 431
def self.prepended(klass) klass.class_eval do OPTIONS.each do |option| alias_method :"#{option}_without_deprecation=", :"#{option}=" define_method(:"#{option}=") do |value| Mongoid::Warnings.send(:"warn_#{option}_deprecated") send(:"#{option}_without_deprecation=", value) end end end end