From 8bb659bd61b1c73d5d4a1204137b3888a944fa02 Mon Sep 17 00:00:00 2001 From: tommy aka doge <59783653+dowoge@users.noreply.github.com> Date: Sun, 11 Sep 2022 22:00:48 -0400 Subject: [PATCH] Revert "ultra mega special case (lua string matching fuckery)" This reverts commit 6076d4b17959767dbb6845540ba082d2b1640c76. --- src/modules/commands/maps_init.lua | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/modules/commands/maps_init.lua b/src/modules/commands/maps_init.lua index a882134..2bd6c89 100644 --- a/src/modules/commands/maps_init.lua +++ b/src/modules/commands/maps_init.lua @@ -49,7 +49,8 @@ for _, game in next, API.GAMES do if type(k)=='string' then for i = 1, self.count do local v = self[i] - if type(v) == 'table' and v.DisplayName:lower():find(tostring(k:gsub('%%', '%%%%'):gsub('^%^', '%%^'):gsub('%$$', '%%$'):gsub('%(', '%%('):gsub('%)', '%%)'):gsub('%.', '%%.'):gsub('%[', '%%['):gsub('%]', '%%]'):gsub('%*', '%%*'):gsub('%+', '%%+'):gsub('%-', '%%-'):gsub('%?', '%%?')):lower()) then + + if type(v) == 'table' and v.DisplayName:lower():find(tostring(k):lower()) then return v end end