mirror of
https://github.com/Ocelot-Social-Community/Ocelot-Social.git
synced 2025-12-13 07:46:06 +00:00
refactor: display server errors on the logs
So, this might clutter our CI but I found it so helpful to turn this on. Our seeds are riddled with runtime errors that we never see. It's also easier to debug the tests if you can see the actual errors thrown by the backend. Let's see how CI log output looks like after this.
This commit is contained in:
parent
f3788b84a5
commit
e52cb5bee7
@ -87,6 +87,8 @@ const createServer = (options?) => {
|
||||
uploads: false,
|
||||
tracing: !!CONFIG.DEBUG,
|
||||
formatError: (error) => {
|
||||
// eslint-disable-next-line no-console
|
||||
console.error(error.originalError)
|
||||
if (error.message === 'ERROR_VALIDATION') {
|
||||
return new Error(error.originalError.details.map((d) => d.message))
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user