feat: complete tree shell cutover and regression coverage
This commit is contained in:
@@ -0,0 +1,12 @@
|
||||
const MNOTE_WEB_AUTH_COOKIE_PATH = "/api/auth/mnote-web-token";
|
||||
|
||||
export async function ensureMnoteWebAuthCookie(): Promise<void> {
|
||||
const response = await fetch(MNOTE_WEB_AUTH_COOKIE_PATH, {
|
||||
method: "GET",
|
||||
credentials: "include",
|
||||
cache: "no-store",
|
||||
});
|
||||
if (!response.ok) {
|
||||
throw new Error("mnote-web 鉴权 cookie 准备失败");
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user