Change skip_authenticity_token by :null_session
This commit is contained in:
parent
f1af878c9e
commit
738283dddd
2 changed files with 1 additions and 2 deletions
|
@ -1,7 +1,7 @@
|
|||
class ApplicationController < ActionController::Base
|
||||
# Prevent CSRF attacks by raising an exception.
|
||||
# For APIs, you may want to use :null_session instead.
|
||||
protect_from_forgery with: :exception
|
||||
protect_from_forgery with: :null_session
|
||||
|
||||
rescue_from CanCan::AccessDenied do |exception|
|
||||
redirect_to root_url, alert: exception.message
|
||||
|
|
|
@ -1,5 +1,4 @@
|
|||
class TransactionsController < ApplicationController
|
||||
|
||||
def index
|
||||
@transactions = Transaction.all
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue