aboutsummaryrefslogtreecommitdiff
path: root/src/store
diff options
context:
space:
mode:
Diffstat (limited to 'src/store')
-rw-r--r--src/store/actions/user.ts2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/store/actions/user.ts b/src/store/actions/user.ts
index 46f96d9a..cb5e3dc1 100644
--- a/src/store/actions/user.ts
+++ b/src/store/actions/user.ts
@@ -1,3 +1,4 @@
+import AsyncStorage from '@react-native-community/async-storage';
import {Action, ThunkAction} from '@reduxjs/toolkit';
import {
getProfilePic,
@@ -157,6 +158,7 @@ export const logout = (): ThunkAction<
Action<string>
> => async (dispatch) => {
try {
+ AsyncStorage.clear();
dispatch({type: userLoggedIn.type, payload: {userId: '', username: ''}});
} catch (error) {
console.log(error);