Common: Simplify _make_credentials()

This commit is contained in:
Mike Salvatore 2022-07-18 08:14:01 -04:00
parent 9e7963afc0
commit acf12c2de1
1 changed files with 1 additions and 3 deletions

View File

@ -57,13 +57,11 @@ class CredentialsSchema(Schema):
if not any(credentials.values()): if not any(credentials.values()):
raise InvalidCredentialsError("At least one credentials component must be defined") raise InvalidCredentialsError("At least one credentials component must be defined")
parsed_credentials = { return {
key: CredentialsSchema._build_credential_component(credential_component_mapping) key: CredentialsSchema._build_credential_component(credential_component_mapping)
for key, credential_component_mapping in credentials.items() for key, credential_component_mapping in credentials.items()
} }
return parsed_credentials
@staticmethod @staticmethod
def _build_credential_component( def _build_credential_component(
credential_component: CredentialComponentMapping, credential_component: CredentialComponentMapping,