Ruby on Rails | Screencasts | Download | Documentation | Weblog | Community | Source

Changeset 6718

Show
Ignore:
Timestamp:
05/11/07 16:30:57 (1 year ago)
Author:
minam
Message:

don't assume the http authorization header will be nil, since some configurations will pass it through as an empty string

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/actionpack/lib/action_controller/http_authentication.rb

    r6700 r6718  
    8787 
    8888      def authenticate(controller, &login_procedure) 
    89         if authorization(controller.request) 
     89        if authorization(controller.request).blank? 
     90          false 
     91        else 
    9092          login_procedure.call(*user_name_and_password(controller.request)) 
    91         else 
    92           false 
    9393        end 
    9494      end