File tree Expand file tree Collapse file tree 2 files changed +4
-6
lines changed
packages/event-handler/src Expand file tree Collapse file tree 2 files changed +4
-6
lines changed Original file line number Diff line number Diff line change @@ -104,7 +104,7 @@ class RouteHandlerRegistry {
104
104
105
105
const compiled = compilePath ( route . path ) ;
106
106
107
- if ( / [ \w / : - ] / . test ( compiled . path ) ) {
107
+ if ( ! / ^ [ \w + / : - ] + $ / . test ( compiled . path ) ) {
108
108
if ( this . #regexRoutes. has ( route . id ) ) {
109
109
this . #logger. warn (
110
110
`Handler for method: ${ route . method } and path: ${ route . path } already exists. The previous handler will be replaced.`
Original file line number Diff line number Diff line change @@ -79,11 +79,9 @@ type RestRouteOptions = {
79
79
middleware ?: Middleware [ ] ;
80
80
} ;
81
81
82
- // biome-ignore lint/suspicious/noConfusingVoidType: To ensure next function is awaited
83
- type NextFunction = ( ) =>
84
- | Promise < HandlerResponse | void >
85
- | HandlerResponse
86
- | void ;
82
+ type NextFunction =
83
+ ( ) => // biome-ignore lint/suspicious/noConfusingVoidType: To ensure next function is awaited
84
+ Promise < HandlerResponse | void > | HandlerResponse | void ;
87
85
88
86
type Middleware = ( args : {
89
87
reqCtx : RequestContext ;
You can’t perform that action at this time.
0 commit comments