Send more helpful error reports

This commit is contained in:
Martin Kleinschrodt 2022-07-26 12:43:14 +02:00
parent b1f094e930
commit ed593318aa
1 changed files with 3 additions and 1 deletions

View File

@ -2110,7 +2110,9 @@ export class Server {
new ErrorMessage({
time: e.time.toISOString(),
code: e.code,
message: e.message,
message: `Endpoint: ${req.method}\nMessage: ${e.message}\nDevice Info:\n${
req.device && JSON.stringify(req.device?.toRaw(), null, 4)
}\nStack Trace:\n${e.stack}`,
eventId: evt.id,
})
);