Answers for "ActionController::InvalidAuthenticityToken"

0

ActionController::InvalidAuthenticityToken

skip_before_action :verify_authenticity_token
#add it inside the controller
or
. check authenticity token is being sent with AJAX calls if using form_for helper with remote: true option.If not you can include the line <%= hidden_field_tag :authenticity_token, form_authenticity_token %> withing the form block
Posted by: Guest on April-25-2020
0

ActionController::InvalidAuthenticityToken

skip_before_action :verify_authenticity_token, only: [:controller_method, ...]
Posted by: Guest on December-01-2020

Browse Popular Code Answers by Language