Sha256: bd94dfc211e00613c6eb3999b61c82a5677c5a33522f74911ef9d4d880b38963
Contents?: true
Size: 388 Bytes
Versions: 6
Compression:
Stored size: 388 Bytes
Contents
class ApplicationController < ActionController::Base include FunWithJsonApi::ControllerMethods rescue_from FunWithJsonApi::Exception, with: :render_fun_with_json_api_exception # Prevent CSRF attacks by raising an exception. # For APIs, you may want to use :null_session instead. protect_from_forgery with: :exception def echo render json: params.slice(:data) end end
Version data entries
6 entries across 6 versions & 1 rubygems