Class: Admin::RobotsTxtController
- Inherits:
-
AdminController
- Object
- AdminController
- Admin::RobotsTxtController
- Defined in:
- app/controllers/admin/robots_txt_controller.rb
Instance Method Summary collapse
Instance Method Details
#reset ⇒ Object
15 16 17 18 |
# File 'app/controllers/admin/robots_txt_controller.rb', line 15 def reset SiteSetting.overridden_robots_txt = "" render json: { robots_txt: original_robots_txt, overridden: false } end |
#show ⇒ Object
4 5 6 |
# File 'app/controllers/admin/robots_txt_controller.rb', line 4 def show render json: { robots_txt: current_robots_txt, overridden: @overridden } end |
#update ⇒ Object
8 9 10 11 12 13 |
# File 'app/controllers/admin/robots_txt_controller.rb', line 8 def update params.require(:robots_txt) SiteSetting.overridden_robots_txt = params[:robots_txt] render json: { robots_txt: current_robots_txt, overridden: @overridden } end |