From: Matías Aguirre Date: Tue, 23 Nov 2010 13:08:32 +0000 (-0200) Subject: Little improve on custom user class import. Refs gh-3 X-Git-Url: https://git.parisson.com/?a=commitdiff_plain;h=0f760aa7010d6e92df5b0e7faab32cf1244cd1a5;p=django-social-auth.git Little improve on custom user class import. Refs gh-3 --- diff --git a/social_auth/models.py b/social_auth/models.py index c09137a..b43a95e 100644 --- a/social_auth/models.py +++ b/social_auth/models.py @@ -23,7 +23,7 @@ try: # try to import User model override and validate needed fields if not all(callable(getattr(User, name, None)) for name in MANDATORY_METHODS): raise AttributeError, 'Some mandatory methods missing' -except: # fail silently and fallback to auth.User on any error +except AttributeError: # fail silently on missing setting from django.contrib.auth.models import User