Cookies
This commit is contained in:
parent
df19c1094c
commit
715fe5c318
@ -18,7 +18,7 @@ export async function login(username: string, password: string) {
|
|||||||
useCookies().set('token', response.data.token as string, {
|
useCookies().set('token', response.data.token as string, {
|
||||||
// for whole domain
|
// for whole domain
|
||||||
// @TODO : #190
|
// @TODO : #190
|
||||||
// domain: window.location.hostname.split('.').slice(-2).join('.')
|
domain: window.location.hostname.split('.').slice(-2).join('.')
|
||||||
})
|
})
|
||||||
return { success: true, token: response.data.token }
|
return { success: true, token: response.data.token }
|
||||||
} catch (error: any) {
|
} catch (error: any) {
|
||||||
|
@ -108,7 +108,7 @@ export const useGameStore = defineStore('game', {
|
|||||||
useCookies().remove('token', {
|
useCookies().remove('token', {
|
||||||
// for whole domain
|
// for whole domain
|
||||||
// @TODO : #190
|
// @TODO : #190
|
||||||
// domain: window.location.hostname.split('.').slice(-2).join('.')
|
domain: window.location.hostname.split('.').slice(-2).join('.')
|
||||||
})
|
})
|
||||||
|
|
||||||
// this.isAssetsLoaded = false
|
// this.isAssetsLoaded = false
|
||||||
|
Loading…
x
Reference in New Issue
Block a user