diff --git a/actionpack/lib/action_controller/metal/request_forgery_protection.rb b/actionpack/lib/action_controller/metal/request_forgery_protection.rb index bbf0d57ac98..354b1d8eeed 100644 --- a/actionpack/lib/action_controller/metal/request_forgery_protection.rb +++ b/actionpack/lib/action_controller/metal/request_forgery_protection.rb @@ -129,13 +129,12 @@ module ActionController # :nodoc: # # If you need to add verification to the beginning of the callback chain, use prepend: true. # * :with - Set the method to handle unverified request. + # Note if default_protect_from_forgery is true, Rails call protect_from_forgery with with :exception. # # Built-in unverified request handling methods are: # * :exception - Raises ActionController::InvalidAuthenticityToken exception. # * :reset_session - Resets the session. # * :null_session - Provides an empty session during request but doesn't reset it completely. Used as default if :with option is not specified. - # Note if default_protect_from_forgery is true, Rails call protect_from_forgery with with :exception. - # This might not be intuitive as the method itself treats :with as :null_session by default. # # You can also implement custom strategy classes for unverified request handling: #