def _get_or_create_user_list_for_site(sailthru_client, site=None, default_list_name=None):
 if (site and (site.get('id') != settings.SITE_ID)):
  list_name = (site.get('domain', '').replace('.', '_') + '_user_list')
 else:
  list_name = default_list_name
 sailthru_list = _get_or_create_user_list(sailthru_client, list_name)
 return (list_name if sailthru_list else default_list_name)

def _get_or_create_user_list_for_site ( sailthru_client , site = None , default_list_name = None ) : if ( site and ( site . get ( 'id' ) != settings . SITE_ID ) ) : list_name = ( site . get ( 'domain' , '' ) . replace ( '.' , '_' ) + '_user_list' ) else : list_name = default_list_name sailthru_list = _get_or_create_user_list ( sailthru_client , list_name ) return ( list_name if sailthru_list else default_list_name )
get the user list name from cache if exists else create one and return the name .