Compare commits

...

2 Commits

Author SHA1 Message Date
Thijs Schreijer
4c86241cd3
Merge dce7073e6a0be9a899e720e3dca47c765a9eff9f into fddde111f7fe9ad5417d75ebbd70429d13eaad97 2023-04-17 17:29:05 +01:00
Thijs Schreijer
dce7073e6a fix silently redirecting
fixes #35

I suspect this will break a lot of existing code. Not nice, but probably for the better.
2015-03-08 16:33:11 +01:00

View File

@ -118,12 +118,13 @@ local function request(url, body)
local stringrequest = type(url) == "string"
if stringrequest then
url = urlstring_totable(url, body, result_table)
url.redirect = false
else
url.url = default_https_port(url.url)
end
if http.PROXY or url.proxy then
return nil, "proxy not supported"
elseif url.redirect then
elseif url.redirect ~= false then
return nil, "redirect not supported"
elseif url.create then
return nil, "create function not permitted"