From 0928c3f2945339437eda2d555d2846b02f06950f Mon Sep 17 00:00:00 2001 From: Vipul A M Date: Sat, 31 Jan 2015 12:24:44 +0530 Subject: Callback#merge merges options for a callback skip instead of a callback. Renamed it to indicate what it actually does. --- activesupport/lib/active_support/callbacks.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'activesupport/lib/active_support') diff --git a/activesupport/lib/active_support/callbacks.rb b/activesupport/lib/active_support/callbacks.rb index 0f1de8b076..98b8f0d34a 100644 --- a/activesupport/lib/active_support/callbacks.rb +++ b/activesupport/lib/active_support/callbacks.rb @@ -373,7 +373,7 @@ module ActiveSupport def filter; @key; end def raw_filter; @filter; end - def merge(chain, new_options) + def merge_conditional_options(chain, new_options) options = { :if => @if.dup, :unless => @unless.dup @@ -701,7 +701,7 @@ module ActiveSupport filter = chain.find {|c| c.matches?(type, filter) } if filter && options.any? - new_filter = filter.merge(chain, options) + new_filter = filter.merge_conditional_options(chain, options) chain.insert(chain.index(filter), new_filter) end -- cgit v1.2.3