class ActiveSupport::Callbacks::Filters::After

def apply(callback_sequence)

def apply(callback_sequence)
  callback_sequence.after(self)
end

def call(env)

def call(env)
  target = env.target
  value  = env.value
  halted = env.halted
  if (!halted || !@halting) && user_conditions.all? { |c| c.call(target, value) }
    user_callback.call target, value
  end
  env
end

def initialize(user_callback, user_conditions, chain_config)

def initialize(user_callback, user_conditions, chain_config)
  halting = chain_config[:skip_after_callbacks_if_terminated]
  @user_callback, @user_conditions, @halting = user_callback, user_conditions, halting
  freeze
end