mirror of
https://github.com/rails/rails.git
synced 2022-11-09 12:12:34 -05:00
remove deprecation warning
This deprecation was released in 4.1.0 and can be removed for 4.2.0, deprecation message / handling is no longer necessary.
This commit is contained in:
parent
33d6e3be62
commit
b342d2baef
2 changed files with 4 additions and 6 deletions
|
@ -1,3 +1,7 @@
|
||||||
|
* Remove deprecated string based terminators for `ActiveSupport::Callbacks`.
|
||||||
|
|
||||||
|
*Eileen M. Uchitelle*
|
||||||
|
|
||||||
* Fixed an issue when using
|
* Fixed an issue when using
|
||||||
`ActiveSupport::NumberHelper::NumberToDelimitedConverter` to
|
`ActiveSupport::NumberHelper::NumberToDelimitedConverter` to
|
||||||
convert a value that is an `ActiveSupport::SafeBuffer` introduced
|
convert a value that is an `ActiveSupport::SafeBuffer` introduced
|
||||||
|
|
|
@ -724,12 +724,6 @@ module ActiveSupport
|
||||||
# would call <tt>Audit#save</tt>.
|
# would call <tt>Audit#save</tt>.
|
||||||
def define_callbacks(*names)
|
def define_callbacks(*names)
|
||||||
options = names.extract_options!
|
options = names.extract_options!
|
||||||
if options.key?(:terminator) && String === options[:terminator]
|
|
||||||
ActiveSupport::Deprecation.warn "String based terminators are deprecated, please use a lambda"
|
|
||||||
value = options[:terminator]
|
|
||||||
line = class_eval "lambda { |result| #{value} }", __FILE__, __LINE__
|
|
||||||
options[:terminator] = lambda { |target, result| target.instance_exec(result, &line) }
|
|
||||||
end
|
|
||||||
|
|
||||||
names.each do |name|
|
names.each do |name|
|
||||||
class_attribute "_#{name}_callbacks"
|
class_attribute "_#{name}_callbacks"
|
||||||
|
|
Loading…
Reference in a new issue