Class: Api::AlgoliumController
- Inherits:
-
ApplicationController
- Object
- ActionController::API
- ApplicationController
- Api::AlgoliumController
- Defined in:
- app/controllers/api/algolium_controller.rb
Instance Method Summary collapse
Methods included from Response
Instance Method Details
#create ⇒ Object
7 8 9 10 11 12 13 14 |
# File 'app/controllers/api/algolium_controller.rb', line 7 def create if current_user.has_role? :jogl_admin UpdateObjectsAlgolia.perform_async render json: { data: 'The objects are updating' }, status: :ok else render json: { data: 'Forbidden' }, status: :forbidden end end |