add types and fix loading
This commit is contained in:
8
src/routes/logout/+page.server.ts
Normal file
8
src/routes/logout/+page.server.ts
Normal file
@@ -0,0 +1,8 @@
|
||||
import { logout } from '$api/authService';
|
||||
import type { RequestEvent } from '@sveltejs/kit';
|
||||
import { redirect } from '@sveltejs/kit';
|
||||
|
||||
export const load = async (event: RequestEvent) => {
|
||||
await logout(event);
|
||||
redirect(303, '/login');
|
||||
};
|
||||
Reference in New Issue
Block a user