mirror of
https://github.com/kenzok8/small-package
synced 2025-01-08 13:27:36 +08:00
update 2022-06-28 08:57:04
This commit is contained in:
parent
26902d4705
commit
b1b6c74711
@ -582,9 +582,9 @@ function sub_info_get()
|
||||
_, len = string.gsub(s.address, '[^\n]+', "")
|
||||
if len and len > 1 then return end
|
||||
sub_url = s.address
|
||||
info = luci.sys.exec(string.format("curl -sLI -m 10 -w 'http_code='%%{http_code} -H 'User-Agent: Clash' '%s'", sub_url))
|
||||
info = luci.sys.exec(string.format("curl -sLI -X GET -m 10 -w 'http_code='%%{http_code} -H 'User-Agent: Clash' '%s'", sub_url))
|
||||
if not info or tonumber(string.sub(string.match(info, "http_code=%d+"), 11, -1)) ~= 200 then
|
||||
info = luci.sys.exec(string.format("curl -sLI -m 10 -w 'http_code='%%{http_code} -H 'User-Agent: Quantumultx' '%s'", sub_url))
|
||||
info = luci.sys.exec(string.format("curl -sLI -X GET -m 10 -w 'http_code='%%{http_code} -H 'User-Agent: Quantumultx' '%s'", sub_url))
|
||||
end
|
||||
if info then
|
||||
http_code=string.sub(string.match(info, "http_code=%d+"), 11, -1)
|
||||
|
Loading…
Reference in New Issue
Block a user