Fix styling & alignment issues
This commit is contained in:
@@ -0,0 +1,12 @@
|
||||
import type { LayoutServerLoad } from "./$types";
|
||||
import { error } from "@sveltejs/kit";
|
||||
import { prisma } from "$lib/db";
|
||||
|
||||
// const authorizedRoles - Not an admin gate, therefore all authenticated roles are authorized.
|
||||
|
||||
export const load: LayoutServerLoad = async ({ locals }) => {
|
||||
const user = await prisma.user.findUnique({ where: { id: locals.user?.id } });
|
||||
if (!user) {
|
||||
throw error(403, "not authorized");
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user