replaced email with username
This commit is contained in:
@@ -12,7 +12,7 @@ export default async function collections(
|
||||
) {
|
||||
const session = await getServerSession(req, res, authOptions);
|
||||
|
||||
if (!session?.user?.email) {
|
||||
if (!session?.user?.username) {
|
||||
return res.status(401).json({ response: "You must be logged in." });
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user