Skip to content

Commit 88ece3f

Browse files
committed
fix(javascript-sdk): allowed-error-messages
1 parent 39620c4 commit 88ece3f

File tree

2 files changed

+3
-0
lines changed

2 files changed

+3
-0
lines changed

packages/javascript-sdk/src/oauth2-client/index.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,8 @@ const allowedErrors = {
5454

5555
// PingOne login error
5656
LoginRequired: 'User authentication is required',
57+
58+
RequestRequiresConsent: 'The request requires consent.',
5759
};
5860

5961
/**

packages/javascript-sdk/src/token-manager/index.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -168,6 +168,7 @@ abstract class TokenManager {
168168
allowedErrors.FailedToFetch !== err.message &&
169169
allowedErrors.NetworkError !== err.message &&
170170
allowedErrors.InteractionNotAllowed !== err.message &&
171+
allowedErrors.RequestRequiresConsent !== err.message &&
171172
// Check for Ping Identity Login Required error
172173
// Long message, so just check substring
173174
!err.message.includes(allowedErrors.LoginRequired) &&

0 commit comments

Comments
 (0)