diff --git a/packages/client/src/components/dialogs/LogoutAllSessionDialog/index.js b/packages/client/src/components/dialogs/LogoutAllSessionDialog/index.js index e8da53b673..9887a41f83 100644 --- a/packages/client/src/components/dialogs/LogoutAllSessionDialog/index.js +++ b/packages/client/src/components/dialogs/LogoutAllSessionDialog/index.js @@ -35,7 +35,7 @@ import ModalDialogContainer from "../ModalDialogContainer"; const LogoutAllSessionDialog = ({ t, - connections, + selection, displayName, visible, isLoading, @@ -55,7 +55,7 @@ const LogoutAllSessionDialog = ({ }; const onClickLogout = () => { - const exceptId = connections[0]?.id; + const exceptId = selection[0]?.connections[0]?.id; if (!isChecked) { onLogoutAllSessions(t); onClose(); diff --git a/packages/client/src/pages/PortalSettings/categories/security/sessions/index.js b/packages/client/src/pages/PortalSettings/categories/security/sessions/index.js index 75d9b235a8..7be34e439f 100644 --- a/packages/client/src/pages/PortalSettings/categories/security/sessions/index.js +++ b/packages/client/src/pages/PortalSettings/categories/security/sessions/index.js @@ -80,9 +80,9 @@ const Sessions = ({ displayName, clearSelection, setDataFromSocket, - connections, updateAllSessions, platformData, + selection, fetchData, isLoading, viewAs, @@ -180,7 +180,7 @@ const Sessions = ({ t={t} visible={logoutAllDialogVisible} isLoading={isLoading} - connections={connections} + selection={selection} displayName={displayName} onClose={() => setLogoutAllDialogVisible(false)} onLogoutAllSessions={onClickLogoutAllSessions} @@ -200,10 +200,10 @@ export default inject(({ settingsStore, setup, peopleStore }) => { displayName, clearSelection, setDataFromSocket, - connections, updateAllSessions, platformData, fetchData, + selection, isLoading, onClickLogoutAllSessions, onClickLogoutAllExceptThis, @@ -228,9 +228,9 @@ export default inject(({ settingsStore, setup, peopleStore }) => { displayName, clearSelection, setDataFromSocket, - connections, updateAllSessions, platformData, + selection, fetchData, viewAs, setViewAs, diff --git a/packages/client/src/store/SelectionPeopleStore.js b/packages/client/src/store/SelectionPeopleStore.js index 5f3b1ced14..e42f3c8b35 100644 --- a/packages/client/src/store/SelectionPeopleStore.js +++ b/packages/client/src/store/SelectionPeopleStore.js @@ -524,7 +524,7 @@ class SelectionStore { onClickLogoutAllSessions = async (t) => { const { removeAllActiveSessionsById } = this.settingsSetupStore; - const userId = this.connections[0]?.userId; + const userId = this.selection[0]?.connections[0]?.userId; if (!userId) return toastr.error(t("The user is already logged out")); @@ -543,7 +543,8 @@ class SelectionStore { onClickLogoutAllExceptThis = async (t, id) => { const { removeAllExceptThisEventId } = this.settingsSetupStore; - const exceptId = this.connections[0]?.id; + + const exceptId = this.selection[0]?.connections[0]?.id; if (!exceptId) return toastr.error(t("The user is already logged out"));