Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import { getServerSession } from "next-auth/next"
- export default async function handler(req, res) {
- const session = await getServerSession(req, res);
- if (!session) {
- res.status(401).json({ message: "You must be logged in." });
- return;
- }
Advertisement
Add Comment
Please, Sign In to add comment