mirror of
https://github.com/hexastack/hexabot
synced 2025-02-23 21:04:15 +00:00
fix: apply feedback updates
This commit is contained in:
parent
d883e99eb3
commit
3165b3b8de
@ -59,7 +59,7 @@ export const useLogout = (
|
|||||||
const { logoutRedirection } = useLogoutRedirection();
|
const { logoutRedirection } = useLogoutRedirection();
|
||||||
const { toast } = useToast();
|
const { toast } = useToast();
|
||||||
const { t } = useTranslate();
|
const { t } = useTranslate();
|
||||||
const postDisconnectionSignal = useBroadcastChannel("session");
|
const broadcastLogoutAcrossTabs = useBroadcastChannel("session");
|
||||||
|
|
||||||
return useMutation({
|
return useMutation({
|
||||||
...options,
|
...options,
|
||||||
@ -70,7 +70,7 @@ export const useLogout = (
|
|||||||
},
|
},
|
||||||
onSuccess: async () => {
|
onSuccess: async () => {
|
||||||
queryClient.removeQueries([CURRENT_USER_KEY]);
|
queryClient.removeQueries([CURRENT_USER_KEY]);
|
||||||
postDisconnectionSignal("logout");
|
broadcastLogoutAcrossTabs("logout");
|
||||||
await logoutRedirection();
|
await logoutRedirection();
|
||||||
toast.success(t("message.logout_success"));
|
toast.success(t("message.logout_success"));
|
||||||
},
|
},
|
||||||
|
Loading…
Reference in New Issue
Block a user