hook, store 리네이밍

This commit is contained in:
static
2024-12-27 21:50:04 +09:00
parent 400438c395
commit 1aafe126d6
11 changed files with 61 additions and 48 deletions

View File

@@ -1,5 +1,5 @@
import { callAPI } from "$lib/hooks";
import { accessToken } from "$lib/stores/auth";
import { accessTokenStore } from "$lib/stores";
export const requestLogin = async (email: string, password: string) => {
const res = await callAPI("/api/auth/login", {
@@ -16,6 +16,6 @@ export const requestLogin = async (email: string, password: string) => {
const data = await res.json();
const token = data.accessToken as string;
accessToken.set(token);
accessTokenStore.set(token);
return true;
};