fix(backend): 修复 server.js 语法错误导致 POST /api/pkglist/dedup 返回 HTML
CI / Backend tests (push) Canceled after 0s
CI / Frontend build (push) Canceled after 0s

根因:getRawPackages() 函数体内有多余的 return rawCache,导致模块解析失败,
服务无法启动,前端请求收到上游 HTML 而非 JSON 响应。

修复:移除多余的 return rawCache 和多余的闭合花括号,
使 server.js 恢复正常语法并可通过 node --check。
This commit is contained in:
DuMate
2026-09-22 00:05:54 +08:00
parent 316daa3bdc
commit 8f02af82e2
-2
View File
@@ -141,8 +141,6 @@ function ensureScan() {
function getRawPackages() {
return rawCache || []
}
return rawCache
}
function invalidateScan() {
rawCache = null