turtle/tlang: improve in_keys()

The function references should probably be replaced with the Lua-y form
wsc-master-rebase
cron 2020-11-22 06:52:20 +00:00 committed by Schmappie Eldress
parent 961a0d3803
commit ff4c79f16d
1 changed files with 1 additions and 6 deletions

View File

@ -12,12 +12,7 @@ local function in_list(value, list)
end
local function in_keys(value, list)
for k, v in pairs(list) do
if k == value then
return true
end
end
return false
return list[value] ~= nil
end
-- state