1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00

Merge pull request #29518 from ragesoss/master

Add more explicit guidance on how to fix callback deprecations
This commit is contained in:
Rafael França 2017-06-27 17:44:23 -04:00 committed by GitHub
commit 60b253553c

View file

@ -662,8 +662,10 @@ module ActiveSupport
if options[:if].is_a?(String) || options[:unless].is_a?(String)
ActiveSupport::Deprecation.warn(<<-MSG.squish)
Passing string to :if and :unless conditional options is deprecated
and will be removed in Rails 5.2 without replacement.
Passing string to be evaluated in :if and :unless conditional
options is deprecated and will be removed in Rails 5.2 without
replacement. Pass a symbol for an instance method, or a lamdba,
proc or block, instead.
MSG
end