服务器url存入PATH变量

This commit is contained in:
MrZ626
2021-01-27 21:31:13 +08:00
parent 7217df1829
commit b7575ddc4e
2 changed files with 6 additions and 3 deletions

View File

@@ -547,7 +547,7 @@ do--httpRequest & wsConnect
if client then
function httpRequest(tick,path,method,header,body)
local task,err=client.httpraw{
url="http://krakens.tpddns.cn:10026"..path,
url="http://"..PATH.url..":"..PATH.port..path,
method=method or"GET",
header=header,
body=body,
@@ -566,8 +566,8 @@ do--httpRequest & wsConnect
return
end
local task,err=client.wsraw{
url="ws://krakens.tpddns.cn:10026"..path,
origin="krakens.tpddns.cn",
url="ws://"..PATH.url..":"..PATH.port..path,
origin=PATH.url,
header=header,
}
if task then

View File

@@ -141,6 +141,9 @@ for i=1,#MODOPT do
M.color=COLOR[M.color]
end
PATH={--Network API paths
url="hdustea.3322.org",
port="10026",
api="/tech/api/v1",
appInfo="/app/info",
users="/users",