mirror of
https://github.com/Telecominfraproject/wlan-cloud-ui.git
synced 2025-10-30 02:12:39 +00:00
Make resetting the store synchronous
This commit is contained in:
@@ -27,9 +27,11 @@ const Login = () => {
|
||||
const handleLogin = (email, password) => {
|
||||
authenticateUser({ variables: { email, password } })
|
||||
.then(({ data }) => {
|
||||
client.cache.reset();
|
||||
updateToken(data.authenticateUser);
|
||||
history.push('/');
|
||||
client.resetStore()
|
||||
.then(() => {
|
||||
updateToken(data.authenticateUser);
|
||||
history.push('/');
|
||||
});
|
||||
})
|
||||
.catch(() =>
|
||||
notification.error({
|
||||
|
||||
Reference in New Issue
Block a user