Remove unused method _get_domain_id_from_auth

The _get_domain_id_from_auth method in
keystone.token.controllers.Auth is not used or tested, so remove it.

Change-Id: Ifb20d419f32cbddf7e3fb126b5b8ecfaa50b582b
This commit is contained in:
Brant Knudson 2014-02-09 21:51:33 -06:00
parent 8557e4756e
commit 542851b4a3
1 changed files with 0 additions and 19 deletions

View File

@ -345,25 +345,6 @@ class Auth(controller.V2Controller):
raise exception.Unauthorized(e)
return tenant_id
def _get_domain_id_from_auth(self, auth):
"""Extract domain information from v3 auth dict.
Returns a valid domain_id if it exists, or None if not specified.
"""
# FIXME(henry-nash): This is a placeholder that needs to be
# only called in the v3 context, and the auth.get calls
# converted to the v3 format
domain_id = auth.get('domainId', None)
domain_name = auth.get('domainName', None)
if domain_name:
try:
domain_ref = self.assignment_api.get_domain_by_name(
domain_name)
domain_id = domain_ref['id']
except exception.DomainNotFound as e:
raise exception.Unauthorized(e)
return domain_id
def _get_project_roles_and_ref(self, user_id, tenant_id):
"""Returns the project roles for this user, and the project ref."""