Clean up some corescripts

This commit is contained in:
Lewin Kelly 2023-04-17 12:54:48 +01:00
parent 736186bb75
commit 55d3a622aa
11 changed files with 146 additions and 146 deletions

View File

@ -327,19 +327,19 @@ function trim(s)
return (s:gsub("^%s*(.-)%s*$", "%1"))
end
function splitByWhitespace(text)
if type(text) ~= "string" then
return nil
end
-- function splitByWhitespace(text)
-- if type(text) ~= "string" then
-- return nil
-- end
local terms = {}
for token in string.gmatch(text, "[^%s]+") do
if string.len(token) > 0 then
table.insert(terms, token)
end
end
return terms
end
-- local terms = {}
-- for token in string.gmatch(text, "[^%s]+") do
-- if string.len(token) > 0 then
-- table.insert(terms, token)
-- end
-- end
-- return terms
-- end
function resetSearchBoxGui()
resetButton.Visible = false