chore: adjust safecatch error messaging

This commit is contained in:
Ben Allfree 2023-01-23 15:08:17 +00:00
parent 63841389bc
commit 778405bb22

View File

@ -32,10 +32,10 @@ export const safeCatch = <TIn extends any[], TOut>(
} else if (e.status === 0) {
warn(`Client request aborted (duplicate)`)
} else {
warn(`Unknown PocketBase API error`, JSON.stringify(e))
warn(`Unknown PocketBase API error`, JSON.stringify({ args, e }))
}
} else {
warn(JSON.stringify(e, null, 2))
warn(JSON.stringify({ args, e }, null, 2))
}
throw e
})