Update thunderapi/thunderapi.ts
Browse files- thunderapi/thunderapi.ts +3 -1
thunderapi/thunderapi.ts
CHANGED
|
@@ -2177,6 +2177,8 @@ async function withCaptchaRetry(captchaPath, apiCall) {
|
|
| 2177 |
}
|
| 2178 |
}
|
| 2179 |
|
|
|
|
|
|
|
| 2180 |
// 文件列表路由
|
| 2181 |
apiRouter.post("/files", async (ctx) => {
|
| 2182 |
if (!ensureClient(ctx)) return;
|
|
@@ -2404,7 +2406,7 @@ app.use(frontRouter.routes());
|
|
| 2404 |
app.use(frontRouter.allowedMethods());
|
| 2405 |
|
| 2406 |
// Apply verification middleware to API routes
|
| 2407 |
-
|
| 2408 |
app.use(apiRouter.routes());
|
| 2409 |
app.use(apiRouter.allowedMethods());
|
| 2410 |
|
|
|
|
| 2177 |
}
|
| 2178 |
}
|
| 2179 |
|
| 2180 |
+
apiRouter.use(verifyToken);
|
| 2181 |
+
|
| 2182 |
// 文件列表路由
|
| 2183 |
apiRouter.post("/files", async (ctx) => {
|
| 2184 |
if (!ensureClient(ctx)) return;
|
|
|
|
| 2406 |
app.use(frontRouter.allowedMethods());
|
| 2407 |
|
| 2408 |
// Apply verification middleware to API routes
|
| 2409 |
+
|
| 2410 |
app.use(apiRouter.routes());
|
| 2411 |
app.use(apiRouter.allowedMethods());
|
| 2412 |
|