mirror of
https://github.com/rails/rails.git
synced 2022-11-09 12:12:34 -05:00
Fix Basic Authentication examples
This commit is contained in:
parent
70779a08a0
commit
54af8dfbfc
2 changed files with 3 additions and 3 deletions
|
@ -619,7 +619,7 @@ HTTP basic authentication is an authentication scheme that is supported by the m
|
|||
|
||||
<ruby>
|
||||
class AdminController < ApplicationController
|
||||
http_basic_authenticate_with :name => "humbaba", "5baa61e4"
|
||||
http_basic_authenticate_with :name => "humbaba", :password => "5baa61e4"
|
||||
end
|
||||
</ruby>
|
||||
|
||||
|
|
|
@ -1210,7 +1210,7 @@ To use the authentication system, we specify it at the top of our +PostsControll
|
|||
<ruby>
|
||||
class PostsController < ApplicationController
|
||||
|
||||
http_basic_authenticate_with :name => "dhh", "secret", :except => :index
|
||||
http_basic_authenticate_with :name => "dhh", :password => "secret", :except => :index
|
||||
|
||||
# GET /posts
|
||||
# GET /posts.xml
|
||||
|
@ -1225,7 +1225,7 @@ We also only want to allow authenticated users to delete comments, so in the +Co
|
|||
<ruby>
|
||||
class CommentsController < ApplicationController
|
||||
|
||||
http_basic_authenticate_with :name => "dhh", "secret", :only => :destroy
|
||||
http_basic_authenticate_with :name => "dhh", :password => "secret", :only => :destroy
|
||||
|
||||
def create
|
||||
@post = Post.find(params[:post_id])
|
||||
|
|
Loading…
Reference in a new issue