change render nothing calls to head ok

This commit is contained in:
Albert Yi
2018-06-04 10:18:32 -07:00
parent d0639afa63
commit dd6848912c
2 changed files with 2 additions and 3 deletions

View File

@@ -111,7 +111,7 @@ class ApplicationController < ActionController::Base
flash[:notice] = "This feature isn't available: #{@exception.message}"
respond_to do |fmt|
fmt.html { redirect_back fallback_location: root_path }
fmt.js { render nothing: true, status: 501 }
fmt.js { head 501 }
fmt.json { render template: "static/error", status: 501 }
fmt.xml { render template: "static/error", status: 501 }
end

View File

@@ -17,7 +17,6 @@ class RelatedTagsController < ApplicationController
@tag.related_tags = params[:related_tags]
@tag.related_tags_updated_at = Time.now
@tag.save
render nothing: true
head :ok
end
end