NestJS · Middle · Question 28 of 75

Why can exception filters behave differently in microservices and HTTP?

Explanation

ArgumentsHost.getType() tells you the transport, so one filter can handle several types if needed.

Further reading

Problem with a question

NestJS · Middle · question 28

Test yourself

Take the NestJS · Middle quiz: questions and options are shuffled, and you get a review of your mistakes at the end.

Take this quiz