Permalink
Browse files

use '!' instead of .not for maximum compatibility

  • Loading branch information...
1 parent f28f26c commit a2c350791633f731a72c88c1b7ccbcfa71b11be0 @jakimowicz jakimowicz committed with Jul 7, 2010
Showing with 1 addition and 1 deletion.
  1. +1 −1 generators/authenticated/templates/authenticated_system.rb
@@ -122,7 +122,7 @@ def login_from_basic_auth
# Called from #current_<%= file_name %>. Finaly, attempt to login by an expiring token in the cookie.
# for the paranoid: we _should_ be storing <%= file_name %>_token = hash(cookie_token, request IP)
def login_from_cookie
- <%= file_name %> = cookies[:auth_token].not.blank? and <%= class_name %>.find_by_remember_token(cookies[:auth_token])
+ <%= file_name %> = !cookies[:auth_token].blank? and <%= class_name %>.find_by_remember_token(cookies[:auth_token])
if <%= file_name %> && <%= file_name %>.remember_token?
self.current_<%= file_name %> = <%= file_name %>
handle_remember_cookie! false # freshen cookie token (keeping date)

0 comments on commit a2c3507

Please sign in to comment.