File tree Expand file tree Collapse file tree 1 file changed +5
-3
lines changed
packages/event-handler/src/rest Expand file tree Collapse file tree 1 file changed +5
-3
lines changed Original file line number Diff line number Diff line change @@ -79,7 +79,8 @@ class Router {
79
79
* Registers a custom error handler for specific error types.
80
80
*
81
81
* @param errorType - The error constructor(s) to handle
82
- * @param handler - The error handler function that returns a Promise<ErrorResponse>
82
+ * @param handler - The error handler that returns an
83
+ * error response>
83
84
*/
84
85
public errorHandler < T extends Error > (
85
86
errorType : ErrorConstructor < T > | ErrorConstructor < T > [ ] ,
@@ -106,7 +107,8 @@ class Router {
106
107
/**
107
108
* Registers a custom handler for 404 Not Found errors.
108
109
*
109
- * @param handler - The error handler function that returns a Promise<ErrorResponse>
110
+ * @param handler - The error handler that returns an error
111
+ * response
110
112
*/
111
113
public notFound ( handler : ErrorHandler < NotFoundError > ) : void ;
112
114
public notFound ( ) : MethodDecorator ;
@@ -127,7 +129,7 @@ class Router {
127
129
/**
128
130
* Registers a custom handler for 405 Method Not Allowed errors.
129
131
*
130
- * @param handler - The error handler function that returns a Promise<ErrorResponse>
132
+ * @param handler - The error handler that returns an error response
131
133
*/
132
134
public methodNotAllowed ( handler : ErrorHandler < MethodNotAllowedError > ) : void ;
133
135
public methodNotAllowed ( ) : MethodDecorator ;
You can’t perform that action at this time.
0 commit comments