This commit is contained in:
AFCMS 2021-03-08 16:18:37 +01:00
parent 59ab7e6ae6
commit 84de4ea728
1 changed files with 1 additions and 12 deletions

View File

@ -52,18 +52,7 @@ end
local STATE_READY = 1 local STATE_READY = 1
local STATE_PARAM = 2 local STATE_PARAM = 2
local STATE_PARAM_TYPE = 3 local STATE_PARAM_TYPE = 3
local bad_chars = {} local bad_chars = {"(", ")", ".", "%", "+", "-", "*", "?", "[", "^", "$"}
bad_chars["("] = true
bad_chars[")"] = true
bad_chars["."] = true
bad_chars["%"] = true
bad_chars["+"] = true
bad_chars["-"] = true
bad_chars["*"] = true
bad_chars["?"] = true
bad_chars["["] = true
bad_chars["^"] = true
bad_chars["$"] = true
local function escape(char) local function escape(char)
if bad_chars[char] then if bad_chars[char] then
return "%" .. char return "%" .. char