Done. Needs testing once back online

This commit is contained in:
Tom Moor
2018-07-07 18:09:39 -05:00
parent dd52f4d82a
commit 08cac861ae
3 changed files with 36 additions and 2 deletions

View File

@ -50,6 +50,17 @@ class AuthStore {
}
};
@action
deleteUser = async () => {
await client.post(`/user.delete`, { confirmation: true });
runInAction('AuthStore#updateUser', () => {
this.user = null;
this.team = null;
this.token = null;
});
};
@action
updateUser = async (params: { name: string, avatarUrl: ?string }) => {
this.isSaving = true;