From 977f1cbd0c25e5d5094ea334f909e261d10c2b71 Mon Sep 17 00:00:00 2001 From: Cooldude2606 Date: Sat, 13 Oct 2018 16:29:23 +0100 Subject: [PATCH] table.autokey returns nil rather than error --- modules/ExpGamingLib/control.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/ExpGamingLib/control.lua b/modules/ExpGamingLib/control.lua index 5e8994ef..cf5e9b82 100644 --- a/modules/ExpGamingLib/control.lua +++ b/modules/ExpGamingLib/control.lua @@ -268,7 +268,7 @@ end -- @tparam table tbl the table that will be searched -- @tparam string str the string that will be looked for in the keys function table.autokey(tbl,str) - if not ExpLib.type_error(str,'string','Search string for table.autokey is not a string.') then return end + if not ExpLib.is_type(str,'string') then return end local _return = {} for key,value in pairs(tbl) do if string.contains(string.lower(key),string.lower(str)) then table.insert(_return,value) end