Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJasper Maes <jaspermaes.jm@gmail.com>2018-11-28 21:08:21 +0300
committerJasper Maes <jaspermaes.jm@gmail.com>2018-11-29 10:05:13 +0300
commit1bb4ad9262efde3b7aefddf849480a102763a68f (patch)
treec8dfa743811928645c97ab3f813fe5101010a517 /app/controllers/profiles
parenta5f4627857bddc7e431d0fca6f17560e4b07e0b9 (diff)
Fix deprecation: render :text is deprecated because it does not actually render a text/plain response
Diffstat (limited to 'app/controllers/profiles')
-rw-r--r--app/controllers/profiles/keys_controller.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/app/controllers/profiles/keys_controller.rb b/app/controllers/profiles/keys_controller.rb
index 912421e3d08..dcee8eb7e6e 100644
--- a/app/controllers/profiles/keys_controller.rb
+++ b/app/controllers/profiles/keys_controller.rb
@@ -41,12 +41,12 @@ class Profiles::KeysController < Profiles::ApplicationController
user = UserFinder.new(params[:username]).find_by_username
if user.present?
headers['Content-Disposition'] = 'attachment'
- render text: user.all_ssh_keys.join("\n"), content_type: 'text/plain'
+ render plain: user.all_ssh_keys.join("\n")
else
return render_404
end
rescue => e
- render text: e.message
+ render html: e.message
end
else
return render_404