mirror of
https://github.com/fosrl/pangolin.git
synced 2026-02-04 00:53:49 +00:00
save
This commit is contained in:
@@ -1,16 +0,0 @@
|
||||
import { GetUserResponse } from "@server/routers/user";
|
||||
import { verifySession } from "./verifySession";
|
||||
|
||||
export async function isValidUser(): Promise<GetUserResponse | null> {
|
||||
const user = await verifySession();
|
||||
|
||||
if (!user) {
|
||||
return null;
|
||||
}
|
||||
|
||||
if (!user.emailVerified) {
|
||||
return null;
|
||||
}
|
||||
|
||||
return user;
|
||||
}
|
||||
Reference in New Issue
Block a user