From: Steven Barth Date: Mon, 1 Jun 2009 18:30:41 +0000 (+0000) Subject: Fix query string detection X-Git-Tag: 0.9.0~273 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=8a3f3e860a7e0595007c344e0fdbbba334d2f404;p=oweals%2Fluci.git Fix query string detection --- diff --git a/libs/lucid-http/luasrc/lucid/http/server.lua b/libs/lucid-http/luasrc/lucid/http/server.lua index 70a172621..67e917892 100644 --- a/libs/lucid-http/luasrc/lucid/http/server.lua +++ b/libs/lucid-http/luasrc/lucid/http/server.lua @@ -343,13 +343,8 @@ function Server.parse_headers(self, source) break end until false - - if env.REQUEST_URI:find("?") then - env.SCRIPT_NAME, env.QUERY_STRING = env.REQUEST_URI:match("([^%?]*)%?(.*)") - else - env.SCRIPT_NAME, env.QUERY_STRING = env.REQUEST_URI, nil - end - + + env.SCRIPT_NAME, env.QUERY_STRING = env.REQUEST_URI:match("([^?]*)%??(.*)") return req end