From dce7073e6a0be9a899e720e3dca47c765a9eff9f Mon Sep 17 00:00:00 2001 From: Thijs Schreijer Date: Sun, 8 Mar 2015 16:33:11 +0100 Subject: [PATCH] fix silently redirecting fixes #35 I suspect this will break a lot of existing code. Not nice, but probably for the better. --- src/https.lua | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/https.lua b/src/https.lua index 182877e..740690d 100644 --- a/src/https.lua +++ b/src/https.lua @@ -114,12 +114,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"