(request: FastifyRequest)
| 31 | } |
| 32 | |
| 33 | function buildCleanUrl(request: FastifyRequest): string { |
| 34 | const clean = new URL(request.url, 'http://localhost'); |
| 35 | clean.searchParams.delete('token'); |
| 36 | return `${clean.pathname}${clean.search}`; |
| 37 | } |
| 38 | |
| 39 | /** |
| 40 | * Fastify onRequest 钩子:隧道请求必须携带有效 token |
no test coverage detected