Allow updates just with auth token

Rails usually requires an additional CSRF protection token but when it's
not present we ignore the user's session and use only the OIDC auth
token.
This commit is contained in:
Maikel Linke
2022-11-10 13:01:48 +11:00
committed by David Cook
parent aea6f864d9
commit 4d49266f0f

View File

@@ -3,6 +3,8 @@
# Controller used to provide the API products for the DFC application
module DfcProvider
class BaseController < ActionController::Base
protect_from_forgery with: :null_session
rescue_from ActiveRecord::RecordNotFound, with: :not_found
before_action :check_authorization