def social_auth_by_type_backends(request):
 def context_value():
  data = backends_data(request.user)
  data['backends'] = group_backend_by_type(data['backends'])
  data['not_associated'] = group_backend_by_type(data['not_associated'])
  data['associated'] = group_backend_by_type(data['associated'], key=(lambda assoc: assoc.provider))
  return data
 return {'social_auth': LazyDict(context_value)}

def social_auth_by_type_backends ( request ) : def context_value ( ) : data = backends_data ( request . user ) data [ 'backends' ] = group_backend_by_type ( data [ 'backends' ] ) data [ 'not_associated' ] = group_backend_by_type ( data [ 'not_associated' ] ) data [ 'associated' ] = group_backend_by_type ( data [ 'associated' ] , key = ( lambda assoc : assoc . provider ) ) return data return { 'social_auth' : LazyDict ( context_value ) }
load social auth current user data to context .