Permalink
Browse files

Use str.join over manually putting things together.

Signed-off-by: Chris Lamb <chris@playfire.com>
  • Loading branch information...
1 parent bcdf2c0 commit 15cedb99d2f2590260e5932ec79dd887a542e9da @lamby lamby committed Apr 10, 2012
Showing with 1 addition and 4 deletions.
  1. +1 −4 django_autologin/utils.py
@@ -26,7 +26,4 @@ def login(request, user):
auth.login(request, user)
def get_user_salt(user):
- salt = ''
- for fieldname in app_settings.SALT_FIELDS:
- salt += str(getattr(user, fieldname))
- return salt
+ return "".join(str(getattr(user, x)) for x in app_settings.SALT_FIELDS)

0 comments on commit 15cedb9

Please sign in to comment.