1
0
Fork 0
mirror of synced 2024-07-03 05:20:32 +12:00

Removing spam of unauthorised traces from tests, may be causing stack overflow.

This commit is contained in:
mike12345567 2022-07-04 16:34:59 +01:00
parent 02f6dcf01e
commit abcb94f1a4

View file

@ -72,8 +72,11 @@ router.use(async (ctx, next) => {
error, error,
} }
ctx.log.error(err) ctx.log.error(err)
// unauthorised errors don't provide a useful trace
if (!env.isTest()) {
console.trace(err) console.trace(err)
} }
}
}) })
// authenticated routes // authenticated routes