Skip to content

Commit

Permalink
feat(proxy): Include URL of request in proxy errors (#10508)
Browse files Browse the repository at this point in the history
  • Loading branch information
fc committed Oct 19, 2022
1 parent 8d0a9c1 commit 27e2832
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion packages/vite/src/node/server/middlewares/proxy.ts
Expand Up @@ -52,7 +52,9 @@ export function proxyMiddleware(
const res = originalRes as http.ServerResponse | net.Socket
if ('req' in res) {
config.logger.error(
`${colors.red(`http proxy error:`)}\n${err.stack}`,
`${colors.red(`http proxy error at ${originalRes.req.url}:`)}\n${
err.stack
}`,
{
timestamp: true,
error: err
Expand Down

0 comments on commit 27e2832

Please sign in to comment.