Class: WellKnownsController
- Inherits:
-
ActionController::API
- Object
- ActionController::API
- WellKnownsController
- Defined in:
- app/controllers/well_knowns_controller.rb
Instance Method Summary collapse
Instance Method Details
#show ⇒ Object
4 5 6 7 8 9 10 11 12 13 14 15 |
# File 'app/controllers/well_knowns_controller.rb', line 4 def show well_known = WellKnown.find_by(name: params[:name]) case well_known&.format when :text render plain: well_known.content when :json render json: well_known.content else head :not_found end end |