mirror of
https://github.com/lemeow125/StudE-Frontend.git
synced 2025-06-28 16:25:46 +08:00
Redirect to onboarding page if needed and added some missing functionality to login and logout button
This commit is contained in:
parent
a9acff39e4
commit
90e60250cd
4 changed files with 32 additions and 13 deletions
|
@ -70,7 +70,7 @@ export function UserLogin(user: LoginParams) {
|
|||
return [true];
|
||||
})
|
||||
.catch((error) => {
|
||||
console.log("Login Failed:" + error.response.data);
|
||||
console.log("Login Failed:" + JSON.stringify(error.response.data));
|
||||
return [false, error.response.data];
|
||||
});
|
||||
}
|
||||
|
|
|
@ -49,7 +49,7 @@ export default function CustomDrawerContent(props: {}) {
|
|||
onPress={async () => {
|
||||
dispatch(await clear());
|
||||
await AsyncStorage.clear();
|
||||
navigation.navigate("Home");
|
||||
navigation.navigate("Login");
|
||||
}}
|
||||
>
|
||||
<LogoutIcon size={32} />
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue