⚗️ Implement chat API
This commit is contained in:
@@ -19,7 +19,6 @@ export const getAuthenticatedUser = async (
|
||||
const authenticateByToken = async (
|
||||
apiToken: string
|
||||
): Promise<User | undefined> => {
|
||||
console.log(window)
|
||||
if (typeof window !== 'undefined') return
|
||||
return (await prisma.user.findFirst({
|
||||
where: { apiTokens: { some: { token: apiToken } } },
|
||||
|
||||
Reference in New Issue
Block a user