Skip to content

Commit

Permalink
Fix tests
Browse files Browse the repository at this point in the history
  • Loading branch information
nicohrubec committed Aug 8, 2024
1 parent 22eadbe commit 61d5fe6
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,9 @@ export class ExampleGlobalFilter implements ExceptionFilter {
const ctx = host.switchToHttp();
const response = ctx.getResponse<Response>();
const request = ctx.getRequest<Request>();
const status = exception.getStatus();
console.log('Example global exception filter!');

response.status(status).json({
response.status(400).json({
statusCode: 400,
timestamp: new Date().toISOString(),
path: request.url,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,9 @@ export class ExampleLocalFilter implements ExceptionFilter {
const ctx = host.switchToHttp();
const response = ctx.getResponse<Response>();
const request = ctx.getRequest<Request>();
const status = exception.getStatus();
console.log('Example local exception filter!');

response.status(status).json({
response.status(400).json({
statusCode: 400,
timestamp: new Date().toISOString(),
path: request.url,
Expand Down

0 comments on commit 61d5fe6

Please sign in to comment.