diff options
author | Yehuda Katz + Carl Lerche <ykatz+clerche@engineyard.com> | 2009-08-25 17:34:07 -0700 |
---|---|---|
committer | Yehuda Katz + Carl Lerche <ykatz+clerche@engineyard.com> | 2009-08-25 17:34:07 -0700 |
commit | 5bc66f160d03bd60a748ac65728227ed9e4fc577 (patch) | |
tree | 06ee19cca89e17bb850b23a13ab32a598f885254 /actionpack/lib/action_controller | |
parent | 3a5269eba434b56cca2688218b7687bd7c1bc53c (diff) | |
download | rails-5bc66f160d03bd60a748ac65728227ed9e4fc577.tar.gz rails-5bc66f160d03bd60a748ac65728227ed9e4fc577.tar.bz2 rails-5bc66f160d03bd60a748ac65728227ed9e4fc577.zip |
And the same thing for Basic
Diffstat (limited to 'actionpack/lib/action_controller')
-rw-r--r-- | actionpack/lib/action_controller/metal/http_authentication.rb | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/actionpack/lib/action_controller/metal/http_authentication.rb b/actionpack/lib/action_controller/metal/http_authentication.rb index 473fa164a6..0f35a7c040 100644 --- a/actionpack/lib/action_controller/metal/http_authentication.rb +++ b/actionpack/lib/action_controller/metal/http_authentication.rb @@ -150,7 +150,8 @@ module ActionController def authentication_request(controller, realm) controller.headers["WWW-Authenticate"] = %(Basic realm="#{realm.gsub(/"/, "")}") - controller.__send__ :render, :text => "HTTP Basic: Access denied.\n", :status => :unauthorized + controller.response_body = "HTTP Basic: Access denied.\n" + controller.status = 401 end end |