Closed singhofmarco closed 7 months ago
lucia
I'm using prisma 3.0.1 and prisma-adapter 4.0.0, createSession throws a Prisma exception. It seems like it's ignoring the db fields and tries to send camelCased fields to prisma instead:
PrismaClientValidationError: Invalid `prisma.session.create()` invocation: { data: { id: "znhqg0v3dmu6qjm6p5f51uv6s6tpvimovujx5ftw", userId: "samytgqj90l306j", expiresAt: new Date("2024-02-27T10:49:22.394Z"), + expires_at: DateTime } }
No this is expected. The Prisma adapter uses camel case instead of snake cases with v3 to be consistent with Prisma.
https://lucia-auth.com/upgrade-v3/prisma/
I see, I had forgotten to update my schema... Thanks!
Package
lucia
Describe the bug
I'm using prisma 3.0.1 and prisma-adapter 4.0.0, createSession throws a Prisma exception. It seems like it's ignoring the db fields and tries to send camelCased fields to prisma instead: