aboutsummaryrefslogtreecommitdiffstats
path: root/railties
diff options
context:
space:
mode:
authoryuuji.yaginuma <yuuji.yaginuma@gmail.com>2015-08-06 15:50:28 +0900
committeryuuji.yaginuma <yuuji.yaginuma@gmail.com>2015-08-06 15:50:28 +0900
commit35a734d671b023cfe6a3298088bb18e009ad9bd7 (patch)
treecf9c7e5e872323fbe5f6905821f2e002b1da9060 /railties
parent3d32a50ca1933ee96abbe5db7ee99617fd0c328c (diff)
downloadrails-35a734d671b023cfe6a3298088bb18e009ad9bd7.tar.gz
rails-35a734d671b023cfe6a3298088bb18e009ad9bd7.tar.bz2
rails-35a734d671b023cfe6a3298088bb18e009ad9bd7.zip
stop using deprecated `render :text` in railties
Diffstat (limited to 'railties')
-rw-r--r--railties/lib/rails/application_controller.rb2
-rw-r--r--railties/lib/rails/mailers_controller.rb2
2 files changed, 2 insertions, 2 deletions
diff --git a/railties/lib/rails/application_controller.rb b/railties/lib/rails/application_controller.rb
index 9a29ec21cf..618a09a5b3 100644
--- a/railties/lib/rails/application_controller.rb
+++ b/railties/lib/rails/application_controller.rb
@@ -6,7 +6,7 @@ class Rails::ApplicationController < ActionController::Base # :nodoc:
def require_local!
unless local_request?
- render text: '<p>For security purposes, this information is only available to local requests.</p>', status: :forbidden
+ render html: '<p>For security purposes, this information is only available to local requests.</p>'.html_safe, status: :forbidden
end
end
diff --git a/railties/lib/rails/mailers_controller.rb b/railties/lib/rails/mailers_controller.rb
index 41422a656c..78a857e0f1 100644
--- a/railties/lib/rails/mailers_controller.rb
+++ b/railties/lib/rails/mailers_controller.rb
@@ -26,7 +26,7 @@ class Rails::MailersController < Rails::ApplicationController # :nodoc:
if part = find_part(part_type)
response.content_type = part_type
- render text: part.respond_to?(:decoded) ? part.decoded : part
+ render plain: part.respond_to?(:decoded) ? part.decoded : part
else
raise AbstractController::ActionNotFound, "Email part '#{part_type}' not found in #{@preview.name}##{@email_action}"
end