Skip to content

Commit b8d5819

Browse files
committed
chore: more fixes
1 parent 5597a97 commit b8d5819

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

packages/common/lib/functions/IssuerMetadataUtils.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,10 +18,10 @@ export function getSupportedCredentials(opts?: {
1818
types?: string[][];
1919
format?: OID4VCICredentialFormat | string | (OID4VCICredentialFormat | string)[];
2020
}): Record<string, CredentialConfigurationSupportedV1_0_13> | Array<CredentialConfigurationSupported> {
21-
const {version = OpenId4VCIVersion.VER_1_0_13, types} = opts ?? {}
21+
const { version = OpenId4VCIVersion.VER_1_0_13, types } = opts ?? {};
2222
if (types && Array.isArray(types)) {
2323
if (version < OpenId4VCIVersion.VER_1_0_13) {
24-
return types.flatMap(typeSet => getSupportedCredential({ ...opts, version, types: typeSet }) as Array<CredentialConfigurationSupported>);
24+
return types.flatMap((typeSet) => getSupportedCredential({ ...opts, version, types: typeSet }) as Array<CredentialConfigurationSupported>);
2525
} else {
2626
return types
2727
.map((typeSet) => {
@@ -51,7 +51,7 @@ export function getSupportedCredential(opts?: {
5151
let credentialConfigurationsV11: Array<CredentialConfigurationSupported> | undefined = undefined;
5252
let credentialConfigurationsV13: Record<string, CredentialConfigurationSupportedV1_0_13> | undefined = undefined;
5353
if (version < OpenId4VCIVersion.VER_1_0_12 || issuerMetadata?.credentials_supported) {
54-
credentialConfigurationsV11 = issuerMetadata?.credential_supported ?? [];
54+
credentialConfigurationsV11 = (issuerMetadata?.credentials_supported as Array<CredentialConfigurationSupported>) ?? [];
5555
} else {
5656
credentialConfigurationsV13 =
5757
(issuerMetadata?.credential_configurations_supported as Record<string, CredentialConfigurationSupportedV1_0_13>) ?? {};

0 commit comments

Comments
 (0)