fix: 更新依赖项版本并优化远程应用连接逻辑
This commit is contained in:
@@ -45,7 +45,7 @@ const authFilter = async (req: http.IncomingMessage, res: http.ServerResponse) =
|
||||
return { code: 200, message: '允许访问根路径' };
|
||||
}
|
||||
// 放开首页
|
||||
if (pathname.startsWith('/root/home') || pathname === '/root/cli/docs/') {
|
||||
if (pathname.startsWith('/root/home') || pathname === '/root/cli-center/') {
|
||||
return { code: 200, message: '允许访问首页' };
|
||||
}
|
||||
// 放开api, 以 /api, /v1, /client, /serve 开头的请求
|
||||
@@ -86,7 +86,7 @@ export const proxyRoute = async (req: http.IncomingMessage, res: http.ServerResp
|
||||
let noAdmin = !auth.username;
|
||||
|
||||
const toSetting = () => {
|
||||
res.writeHead(302, { Location: `/root/cli/setting/` });
|
||||
res.writeHead(302, { Location: `/root/cli-center/` });
|
||||
res.end();
|
||||
return true;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user