Prisma adapter uses db[model].update with non‑unique where (AND …) → PrismaClientValidationError
This PR addresses a Prisma adapter bug where
https://github.com/better-auth/better-auth/issues/5929
db[model].update was called with a non-unique where (compound AND), causing a PrismaClientValidationError when updating dynamic organization roles. It ensures updates use a unique selector (e.g., where: { id }) and falls back to updateMany when the filter isn’t unique (refs #5929).https://github.com/better-auth/better-auth/issues/5929
GitHub![Prisma adapter uses db[model].update with non‑unique where (AND ...](https://cdn.answeroverflow.com/embeds/1438151802351779981/0/thumbnail.png)
Is this suited for github? Yes, this is suited for github To Reproduce Configure backend with Prisma & organizations: import { prismaAdapter } from "better-auth/adapters/prisma"; impo...
