warrior 10 часов назад
Родитель
Сommit
03d51cb218
1 измененных файлов с 16 добавлено и 16 удалено
  1. 16 16
      api/routes.ts

+ 16 - 16
api/routes.ts

@@ -69,23 +69,23 @@ router.use(
 
 
 /* 已清洗的社媒接口 */
-// let createTikHubCustomizeRoutes;
-// try {
-//   ({ createTikHubCustomizeRoutes } = await globalThis.loadModule(
-//     'https://repos.fmode.cn/x/fmode-tikhub-api-customize/0.0.3/fmode-tikhub-api-customize.min.js?code=xxxxxxx'
-//   ));
-// } catch (e) {
-//   console.warn("[API Routes] CDN 加载失败, 使用本地模块回退", e);
-//   // ({ createTikHubCustomizeRoutes } = await import('../modules/fmode-tikhub-server/src/mod.ts'));
-// }
+let createTikHubCustomizeRoutes;
+try {
+  ({ createTikHubCustomizeRoutes } = await globalThis.loadModule(
+    'https://repos.fmode.cn/x/fmode-tikhub-api-customize/0.0.3/fmode-tikhub-api-customize.min.js?code=xxxxxxx'
+  ));
+} catch (e) {
+  console.warn("[API Routes] CDN 加载失败, 使用本地模块回退", e);
+  // ({ createTikHubCustomizeRoutes } = await import('../modules/fmode-tikhub-server/src/mod.ts'));
+}
 
-// router.use(
-//   '/tikhub/customize',
-//   createTikHubCustomizeRoutes({
-//     serverURL: 'https://api.tikhub.io/api/v1',
-//     apiKey: 'tKIbAsEM8X+GmE2vHqGW7D/ICwK1Q5V4viKFrWiPB6HholGdLFqZJmmyNw=='
-//   })
-// );
+router.use(
+  '/tikhub/customize',
+  createTikHubCustomizeRoutes({
+    serverURL: 'https://api.tikhub.io/api/v1',
+    apiKey: 'tKIbAsEM8X+GmE2vHqGW7D/ICwK1Q5V4viKFrWiPB6HholGdLFqZJmmyNw=='
+  })
+);
 
 
 // let createPinterestRouter;