Skip to content

Commit

Permalink
Be lenient in parsing responses from previous drafts
Browse files Browse the repository at this point in the history
  • Loading branch information
nodh committed Oct 24, 2024
1 parent bc916ce commit 56afc1e
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ sealed class AuthorizationDetails {
* identifiers together with an Access Token in subsequent Credential Requests.
*/
@SerialName("credential_identifiers")
val credentialIdentifiers: Set<String>
val credentialIdentifiers: Set<String>? = null
) : AuthorizationDetails()

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,8 @@ class OidvciPreAuthTest : FreeSpec({
it.shouldBeInstanceOf<AuthorizationDetails.OpenIdCredential>()
// Not supporting different credential datasets for one credential configuration at the moment,
// so we'll just use the credential identifier, see OID4VCI 6.2
val credentialIdentifier = it.credentialIdentifiers.first()
val credentialIdentifier = it.credentialIdentifiers?.first()
?: throw IllegalArgumentException("credential_identifiers")
val credentialRequest = client.createCredentialRequest(
input = WalletService.CredentialRequestInput.CredentialIdentifier(credentialIdentifier),
clientNonce = token.clientNonce,
Expand Down

0 comments on commit 56afc1e

Please sign in to comment.