Skip to content

Commit

Permalink
fix: draft 11
Browse files Browse the repository at this point in the history
Signed-off-by: Timo Glastra <[email protected]>
  • Loading branch information
TimoGlastra committed Nov 8, 2024
1 parent 55590cd commit 0556a42
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions packages/oid4vci/src/credential-offer/credential-offer.ts
Original file line number Diff line number Diff line change
Expand Up @@ -205,7 +205,7 @@ export async function createCredentialOffer(options: CreateCredentialOfferOption

// Draft 11 support
const txCode = grants[preAuthorizedCodeGrantIdentifier].tx_code
if (txCode && options.issuerMetadata.credentialIssuer.originalDraftVersion === Oid4vciDraftVersion.Draft11) {
if (txCode && options.issuerMetadata.originalDraftVersion === Oid4vciDraftVersion.Draft11) {
grants[preAuthorizedCodeGrantIdentifier].user_pin_required = txCode !== undefined
}
}
Expand All @@ -228,7 +228,7 @@ export async function createCredentialOffer(options: CreateCredentialOfferOption
} satisfies CredentialOfferObject)

// Draft 11 support
if (options.issuerMetadata.credentialIssuer.originalDraftVersion === Oid4vciDraftVersion.Draft11) {
if (options.issuerMetadata.originalDraftVersion === Oid4vciDraftVersion.Draft11) {
credentialOfferObject.credentials = credentialOfferObject.credential_configuration_ids
}

Expand Down

0 comments on commit 0556a42

Please sign in to comment.