@@ -586,20 +586,21 @@ def login(request, extra_context=None):
586586 user = User .objects .filter (username = username ).first ()
587587 #
588588 require_consent = []
589- if user .person and not user .person .consent :
590- person = user .person
591- if person .name != person .name_from_draft :
592- require_consent .append ("full name" )
593- if person .ascii != person .name_from_draft :
594- require_consent .append ("ascii name" )
595- if person .biography :
596- require_consent .append ("biography" )
597- if user .communitylist_set .exists ():
598- require_consent .append ("draft notification subscription(s)" )
599- for email in person .email_set .all ():
600- if not email .origin .split (':' )[0 ] in ['author' , 'role' , 'reviewer' , 'liaison' , 'shepherd' , ]:
601- require_consent .append ("email address(es)" )
602589 if user :
590+ if user .person and not user .person .consent :
591+ person = user .person
592+ if person .name != person .name_from_draft :
593+ require_consent .append ("full name" )
594+ if person .ascii != person .name_from_draft :
595+ require_consent .append ("ascii name" )
596+ if person .biography :
597+ require_consent .append ("biography" )
598+ if user .communitylist_set .exists ():
599+ require_consent .append ("draft notification subscription(s)" )
600+ for email in person .email_set .all ():
601+ if not email .origin .split (':' )[0 ] in ['author' , 'role' , 'reviewer' , 'liaison' , 'shepherd' , ]:
602+ require_consent .append ("email address(es)" )
603+
603604 try :
604605 identify_hasher (user .password )
605606 except ValueError :
0 commit comments