ServiceAuthorizationError
Param | Type | Default | Description |
args | Object | | Required - The args object passed to the constructor |
args.publicData | Object | | Required - Data to show in the error |
args.internalData | Object | | Required - Private data that can be logged in the error |
args.publicMessage | string | "An error occurred" | Error message to be shown |
args.httpCode | number | 500 | Http status code for error |
Reply function to respond with the error
Returns:
Object
- Response - Response objectParam | Type | Default | Description |
replyOrResponseToolkit | Object | | Required - Response toolkit - For example 'h' in Hapi, which handles the response |
extraPublicData | Object | {} | Extra public data to shown in the error message |
Last modified 3yr ago