From a93bd11b1d90da5abdef11c2774bb9bafe27bfb1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jos=C3=A9=20Valim?= Date: Wed, 4 May 2011 19:31:43 +0200 Subject: [PATCH] Use remove possible method here. --- actionpack/lib/action_view/test_case.rb | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/actionpack/lib/action_view/test_case.rb b/actionpack/lib/action_view/test_case.rb index 43f9bffe18a..d0317a148b3 100644 --- a/actionpack/lib/action_view/test_case.rb +++ b/actionpack/lib/action_view/test_case.rb @@ -1,5 +1,6 @@ require 'active_support/core_ext/object/blank' require 'active_support/core_ext/module/delegation' +require 'active_support/core_ext/module/remove_method' require 'action_controller' require 'action_controller/test_case' require 'action_view' @@ -129,7 +130,7 @@ module ActionView def say_no_to_protect_against_forgery! _helpers.module_eval do - remove_method :protect_against_forgery? if method_defined?(:protect_against_forgery?) + remove_possible_method :protect_against_forgery? def protect_against_forgery? false end