This commit is contained in:
Rahul 2024-02-29 09:33:34 +01:00
parent 501d8a8d8e
commit 3226975910
76 changed files with 48623 additions and 3401 deletions

16
api/route.js Normal file
View file

@ -0,0 +1,16 @@
// export const dynamic = 'force-dynamic' // defaults to auto
// export async function GET(request) {}
export default async function handler(req, res) {
const session = await getSession(req)
// Check if the user is authenticated
if (!session) {
res.status(401).json({
error: "User is not authenticated",
})
return
}
console.log("_____________________________________________")
// Proceed with the route for authorized users
// ... implementation of the API Route
}