fixed big bug

This commit is contained in:
IonutParau 2025-05-29 18:40:17 +02:00
parent e9de55dbc2
commit 09048f4a93

View File

@ -142,8 +142,9 @@ libcomponent = {
list = function(filter, exact)
checkArg(1, filter, "string", "nil")
local t = component.list()
if not filter then return t end
local list = {}
local list = t
if filter then
list = {}
for addr, kind in pairs(t) do
if type(exact) == "boolean" and exact then
if kind == filter then
@ -159,6 +160,7 @@ libcomponent = {
end
end
end
end
local key = nil
return setmetatable(list, {