In the auth validate() function it builds a list of scope errors and if there are any, it logs them with the request and creates a Boom.forbidden. The problem is that the scopeErrors is then lost. It would be great if it were added to the error instance so it could be used in a onPreResponse handler to construct a useful error message.
In the auth
validate()function it builds a list of scope errors and if there are any, it logs them with the request and creates aBoom.forbidden. The problem is that thescopeErrorsis then lost. It would be great if it were added to the error instance so it could be used in aonPreResponsehandler to construct a useful error message.