diff options
-rw-r--r-- | libs/sgi-webuci/luasrc/sgi/webuci.lua | 5 | ||||
-rw-r--r-- | libs/web/luasrc/http.lua | 2 |
2 files changed, 3 insertions, 4 deletions
diff --git a/libs/sgi-webuci/luasrc/sgi/webuci.lua b/libs/sgi-webuci/luasrc/sgi/webuci.lua index 8801cf447..7bfa2fe13 100644 --- a/libs/sgi-webuci/luasrc/sgi/webuci.lua +++ b/libs/sgi-webuci/luasrc/sgi/webuci.lua @@ -29,9 +29,8 @@ require("luci.util") require("luci.dispatcher") function run(env, vars) - local r = luci.http.Request(env, nil, io.stderr) - r.get = vars - r.post = r.get + local r = luci.http.Request(env, {}, io.stderr) + r.message.params = vars local x = coroutine.create(luci.dispatcher.httpdispatch) diff --git a/libs/web/luasrc/http.lua b/libs/web/luasrc/http.lua index 89385a161..f2c366073 100644 --- a/libs/web/luasrc/http.lua +++ b/libs/web/luasrc/http.lua @@ -52,7 +52,7 @@ function Request.__init__(self, env, instream, errstream) self.message = { env = env, headers = {}, - params = luci.http.protocol.urldecode_params("?"..env.QUERY_STRING), + params = luci.http.protocol.urldecode_params("?"..(env.QUERY_STRING or "")), } setmetatable(self.message.params, {__index = |