fixing device token on logout

This commit is contained in:
Roland Osborne 2023-03-06 11:56:17 -08:00
parent 1fb2907b80
commit 6ee9bd87d0

View File

@ -131,8 +131,7 @@ export function useAppContext() {
updateState({ loggingOut: true });
try {
await messaging().deleteToken();
const token = await messaging().getToken();
updateState({ deviceToken: token });
deviceToken.current = await messaging().getToken();
await clearLogin(state.server, state.token);
}
catch (err) {