Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bugfix: Do not attempt to sign user out if clientNeedsToRefresh is true #5391

Draft
wants to merge 3 commits into
base: staging
Choose a base branch
from
Draft
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 10 additions & 3 deletions web-client/src/presenter/sequences/signOutUserInitiatedSequence.ts
Original file line number Diff line number Diff line change
@@ -1,13 +1,20 @@
import { BROADCAST_MESSAGES } from '@shared/business/entities/EntityConstants';
import { checkClientNeedsToRefresh } from '@web-client/presenter/actions/checkClientNeedsToRefresh';
import { navigateToLoginSequence } from '@web-client/presenter/sequences/Login/navigateToLoginSequence';
import { setLogoutTypeAction } from '@web-client/presenter/actions/setLogoutTypeAction';
import { signOutSequence } from '@web-client/presenter/sequences/signOutSequence';

// The sequence to call when the user voluntarily decides to sign out
export const signOutUserInitiatedSequence = [
setLogoutTypeAction(BROADCAST_MESSAGES.userLogout),
signOutSequence,
navigateToLoginSequence,
checkClientNeedsToRefresh,
{
clientDoesNotNeedToRefresh: [
setLogoutTypeAction(BROADCAST_MESSAGES.userLogout),
signOutSequence,
navigateToLoginSequence,
],
clientNeedsToRefresh: [],
},
] as unknown as (props: {
skipBroadcast?: boolean;
fromModal?: boolean;
Expand Down
Loading