mirror of
https://github.com/makeplane/plane
synced 2025-08-07 19:59:33 +00:00
feat: edit state, help button, loader while login in
This commit is contained in:
@@ -27,11 +27,13 @@ class UserService extends APIService {
|
||||
}
|
||||
|
||||
async currentUser(): Promise<any> {
|
||||
if (!this.getAccessToken()) return null;
|
||||
return this.get(USER_ENDPOINT)
|
||||
.then((response) => {
|
||||
return response?.data;
|
||||
})
|
||||
.catch((error) => {
|
||||
this.purgeAccessToken();
|
||||
throw error?.response?.data;
|
||||
});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user