Class: Voluntary::Api::V1::BaseController
- Inherits:
-
ActionController::Base
- Object
- ActionController::Base
- Voluntary::Api::V1::BaseController
- Defined in:
- app/controllers/voluntary/api/v1/base_controller.rb
Direct Known Subclasses
Instance Method Summary collapse
Instance Method Details
#require_api_key ⇒ Object
9 10 11 |
# File 'app/controllers/voluntary/api/v1/base_controller.rb', line 9 def require_api_key render status: 401, json: { error: 'You need to pass your API key for this request!' } if current_user.nil? end |