Removed getDomain func.

This commit is contained in:
2025-02-09 03:34:33 +01:00
parent fcf96a25ae
commit c21e78c2ec
5 changed files with 5 additions and 23 deletions

View File

@ -1,5 +1,4 @@
import config from '@/application/config'
import { getDomain } from '@/application/utilities'
import { useCookies } from '@vueuse/integrations/useCookies'
import axios from 'axios'
@ -22,7 +21,7 @@ export async function login(username: string, password: string) {
try {
const response = await axios.post(`${config.server_endpoint}/login`, { username, password })
useCookies().set('token', response.data.data.token as string, {
domain: getDomain()
domain: config.domain
})
return { success: true, token: response.data.data.token }
} catch (error: any) {