polyglot/app/controllers/application_controller.rb

6 lines
213 B
Ruby
Raw Normal View History

class ApplicationController < ActionController::Base
protect_from_forgery with: :exception
2018-08-28 13:46:15 +00:00
# before_action :authenticate_user!
protect_from_forgery unless: -> { request.format.json? } # Only accept json
end