#NEWLINE# def _two_factor_needed( domain_name , request ) : #NEWLINE# #INDENT# domain_name = normalize_domain_name ( domain_name ) #NEWLINE# domain = Domain . get_by_name ( domain_name ) #NEWLINE# if domain : #NEWLINE# #INDENT# return ( domain . two_factor_auth and ( not request . user . is_verified ( ) ) )