diff options
Diffstat (limited to 'actionpack/lib/action_controller')
-rw-r--r-- | actionpack/lib/action_controller/http_authentication.rb | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/actionpack/lib/action_controller/http_authentication.rb b/actionpack/lib/action_controller/http_authentication.rb index 269858633e..fbc34d1f2e 100644 --- a/actionpack/lib/action_controller/http_authentication.rb +++ b/actionpack/lib/action_controller/http_authentication.rb @@ -86,10 +86,10 @@ module ActionController end def authenticate(controller, &login_procedure) - if authorization(controller.request) - login_procedure.call(*user_name_and_password(controller.request)) - else + if authorization(controller.request).blank? false + else + login_procedure.call(*user_name_and_password(controller.request)) end end @@ -118,4 +118,4 @@ module ActionController end end end -end
\ No newline at end of file +end |