({ middleware }: App, h: Handler<Request, Response>)
| 28 | } |
| 29 | |
| 30 | export const getRouteFromApp = ({ middleware }: App, h: Handler<Request, Response>) => |
| 31 | middleware.find(({ handler }) => typeof handler === 'function' && handler.name === h.name) |
| 32 | |
| 33 | export const getProtocol = (req: Request): Protocol => { |
| 34 | const proto = req.connection.encrypted ? 'https' : 'http' |