new ResError(properties)
- Description:
- Constructor for ResError class.
- Source:
Properties:
Name |
Type |
Description |
properties.message |
String
|
Error message. |
properties.status |
Number
|
HTTP status code (defaults to 500). |
Parameters:
Name |
Type |
Description |
properties |
Object
|
Properties for the response error. |
Methods
add(key) → {String}
- Description:
- Method to add a ResError instance to resErrors object.
- Source:
Parameters:
Name |
Type |
Description |
key |
String
|
The key to identify the response error. |
Returns:
- The key used to identify the response error. We will use it to identify the response error in the error middlewere.
-
Type
-
String