Skip to content

Commit

Permalink
🐛 Try to fix build error (#121)
Browse files Browse the repository at this point in the history
  • Loading branch information
KATO-Hiro committed Oct 15, 2023
1 parent 093fc7b commit 381e9e1
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/lib/server/database.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
// See:
// https://lucia-auth.com/getting-started/sveltekit/
import { PrismaClient } from '@prisma/client';
// https://www.reddit.com/r/sveltejs/comments/ozt7mk/sveltekit_with_prisma_fix/?rdt=38249
import Prisma, * as PrismaScope from '@prisma/client';

const PrismaClient = Prisma?.PrismaClient || PrismaScope?.PrismaClient;
const client = new PrismaClient();

export default client;

0 comments on commit 381e9e1

Please sign in to comment.