Skip to content

Commit 0972686

Browse files
committed
#RI-5798 - [Regression] 401 error from WS is not handled
1 parent 60e627a commit 0972686

File tree

3 files changed

+4
-3
lines changed

3 files changed

+4
-3
lines changed

redisinsight/ui/src/components/oauth/oauth-jobs/OAuthJobs.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ import { fetchInstancesAction } from 'uiSrc/slices/instances/instances'
88
import {
99
createFreeDbJob,
1010
createFreeDbSuccess,
11-
logoutUser,
11+
logoutUserAction,
1212
oauthCloudJobSelector,
1313
oauthCloudSelector,
1414
setJob,
@@ -56,7 +56,7 @@ const OAuthJobs = () => {
5656
const statusCode = get(error, 'statusCode', 0) as number
5757

5858
if (statusCode === ApiStatusCode.Unauthorized) {
59-
dispatch(logoutUser())
59+
dispatch(logoutUserAction())
6060
}
6161

6262
// eslint-disable-next-line sonarjs/no-nested-switch

redisinsight/ui/src/components/oauth/oauth-sso/oauth-create-db/OAuthCreateDb.spec.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -129,6 +129,7 @@ describe('OAuthCreateDb', () => {
129129
setSSOFlow(OAuthSocialAction.Create),
130130
showOAuthProgress(true),
131131
addInfiniteNotification(INFINITE_MESSAGES.PENDING_CREATE_DB(CloudJobStep.Credentials)),
132+
setSocialDialogState(null),
132133
getPlans()
133134
]
134135
expect(store.getActions()).toEqual(expectedActions)

redisinsight/ui/src/components/oauth/oauth-sso/oauth-create-db/OAuthCreateDb.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,9 +61,9 @@ const OAuthCreateDb = (props: Props) => {
6161
dispatch(setSSOFlow(OAuthSocialAction.Create))
6262
dispatch(showOAuthProgress(true))
6363
dispatch(addInfiniteNotification(INFINITE_MESSAGES.PENDING_CREATE_DB(CloudJobStep.Credentials)))
64+
dispatch(setSocialDialogState(null))
6465

6566
if (isRecommended) {
66-
dispatch(setSocialDialogState(null))
6767
dispatch(createFreeDbJob({
6868
name: CloudJobName.CreateFreeSubscriptionAndDatabase,
6969
resources: {

0 commit comments

Comments
 (0)