You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently, the Prisma exception filter provided by the package maps Prisma exceptions to their corresponding HTTP exceptions, but the message of the HTTP exception is the same as the message of the underlying Prisma exception. This can result in error messages that are explicit.
I am willing to work on a pull request so that this response:
{
"statusCode": 404,
"message": "Not Found"
}
is sent instead of this response:
{
"statusCode": 404,
"message": "[P2025]: An operation failed because it depends on one or more records that were required but not found. No 'User' record(s) (needed to inline the relation on 'FriendInvitation' record(s)) was found for a nested connect on one-to-many relation 'receivedFriendInvitations'."
}
But I'm not sure how to approach this.
The text was updated successfully, but these errors were encountered:
recursive-beast
changed the title
feat: add
feat: add option to use generic http messages in Prisma exception filter
Jul 17, 2023
megane42
added a commit
to megane42/nestjs-prisma
that referenced
this issue
Aug 5, 2023
Currently, the Prisma exception filter provided by the package maps Prisma exceptions to their corresponding HTTP exceptions, but the message of the HTTP exception is the same as the message of the underlying Prisma exception. This can result in error messages that are explicit.
I am willing to work on a pull request so that this response:
is sent instead of this response:
But I'm not sure how to approach this.
The text was updated successfully, but these errors were encountered: