Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
Germey committed Dec 17, 2023
1 parent 752e61b commit edf196e
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/pages/auth/Callback.vue
Original file line number Diff line number Diff line change
Expand Up @@ -25,13 +25,13 @@ export default defineComponent({
this.refreshToken = getCookie('REFRESH_TOKEN');
if (this.accessToken && this.refreshToken) {
// store token to global store
this.$store.dispatch('setAccessToken', this.accessToken);
this.$store.dispatch('setRefreshToken', this.refreshToken);
await this.$store.dispatch('setToken', {
refresh: this.refreshToken,
access: this.accessToken
});
console.debug('set token successfully');
removeCookies();
console.debug('remove cookie for tokens successfully');
// get user info after get access token
this.$store.dispatch('getMe');
if (this.redirect) {
this.$router.push(this.redirect);
}
Expand Down

0 comments on commit edf196e

Please sign in to comment.