mirror of
https://github.com/TangentFoxy/lovebird.git
synced 2025-07-28 11:02:19 +00:00
Fixed bad replace string on for :gsub() on env.json page
This commit is contained in:
@@ -380,7 +380,7 @@ lovebird.pages["env.json"] = [[
|
|||||||
<?lua
|
<?lua
|
||||||
local t = _G
|
local t = _G
|
||||||
local p = req.parsedurl.query.p or ""
|
local p = req.parsedurl.query.p or ""
|
||||||
p = p:gsub("%.+", "%."):match("^[%.]*(.*)[%.]*$")
|
p = p:gsub("%.+", "."):match("^[%.]*(.*)[%.]*$")
|
||||||
if p ~= "" then
|
if p ~= "" then
|
||||||
for x in p:gmatch("[^%.]+") do
|
for x in p:gmatch("[^%.]+") do
|
||||||
t = t[x] or t[tonumber(x)]
|
t = t[x] or t[tonumber(x)]
|
||||||
|
Reference in New Issue
Block a user