diff --git a/package.json b/package.json index 97ecdf86..87db0793 100644 --- a/package.json +++ b/package.json @@ -23,7 +23,8 @@ "node": ">=18" }, "resolutions": { - "node-fetch": "2.6.12" + "node-fetch": "2.6.12", + "@sphereon/pex": "5.0.0-unstable.8" }, "prettier": { "endOfLine": "auto", diff --git a/packages/siop-oid4vp/lib/authorization-response/PresentationExchange.ts b/packages/siop-oid4vp/lib/authorization-response/PresentationExchange.ts index 726f3c6c..2258cd9f 100644 --- a/packages/siop-oid4vp/lib/authorization-response/PresentationExchange.ts +++ b/packages/siop-oid4vp/lib/authorization-response/PresentationExchange.ts @@ -320,7 +320,7 @@ export class PresentationExchange { throw new Error(SIOPErrors.NO_PRESENTATION_SUBMISSION) } - if (!evaluationResults.areRequiredCredentialsPresent || evaluationResults.errors || !evaluationResults.value) { + if (!evaluationResults.areRequiredCredentialsPresent || evaluationResults.errors.length > 0 || !evaluationResults.value) { throw new Error(`message: ${SIOPErrors.COULD_NOT_FIND_VCS_MATCHING_PD}, details: ${JSON.stringify(evaluationResults.errors)}`) } diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 48470c1e..8b1c2c3d 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -6,6 +6,7 @@ settings: overrides: node-fetch: 2.6.12 + '@sphereon/pex': 5.0.0-unstable.8 importers: