remove redis.close causing intermittent failures (#211)
diff --git a/scripts/lua/oauth/github.lua b/scripts/lua/oauth/github.lua
index cb20f44..9d2c208 100644
--- a/scripts/lua/oauth/github.lua
+++ b/scripts/lua/oauth/github.lua
@@ -30,7 +30,6 @@
local httpc = http.new()
local key = utils.concatStrings({'oauth:provider:github:', token})
if redis.exists(red, key) == 1 then
- redis.close(red)
return cjson.decode(redis.get(red, key))
end
diff --git a/scripts/lua/oauth/google.lua b/scripts/lua/oauth/google.lua
index ebdd8fd..aba85ba 100644
--- a/scripts/lua/oauth/google.lua
+++ b/scripts/lua/oauth/google.lua
@@ -29,7 +29,6 @@
local httpc = http.new()
local key = utils.concatStrings({'oauth:provider:google:', token})
if redis.exists(red, key) == 1 then
- redis.close(red)
return cjson.decode(redis.get(red, key))
end
diff --git a/scripts/lua/policies/security/oauth2.lua b/scripts/lua/policies/security/oauth2.lua
index e847fcb..b799d3b 100644
--- a/scripts/lua/policies/security/oauth2.lua
+++ b/scripts/lua/policies/security/oauth2.lua
@@ -74,7 +74,6 @@
-- @return the json object recieved from exchanging tokens with the provider
function exchangeWithRedis(red, token, provider)
-- exchange tokens with the provider
- print (provider)
local loaded, provider = pcall(require, utils.concatStrings({'oauth/', provider}))
if not loaded then