oidc: use safe instead

This commit is contained in:
Girish Ramakrishnan
2025-06-11 23:18:48 +02:00
parent 95eb310a7f
commit 5baa08eb0c

View File

@@ -537,15 +537,12 @@ async function interactionConfirm(req, res, next) {
}
async function interactionAbort(req, res, next) {
try {
const result = {
error: 'access_denied',
error_description: 'End-User aborted interaction',
};
await gOidcProvider.interactionFinished(req, res, result, { mergeWithLastSubmission: false });
} catch (err) {
next(err);
}
const result = {
error: 'access_denied',
error_description: 'End-User aborted interaction',
};
const [error] = await safe(gOidcProvider.interactionFinished(req, res, result, { mergeWithLastSubmission: false }));
if (error) return next(error);
}
async function getClaims(userId/*, use, scope*/) {