mirror of
https://github.com/NeoFlock/neonucleus.git
synced 2025-09-24 09:03:32 +02:00
fixed big bug
This commit is contained in:
parent
e9de55dbc2
commit
09048f4a93
@ -142,8 +142,9 @@ libcomponent = {
|
|||||||
list = function(filter, exact)
|
list = function(filter, exact)
|
||||||
checkArg(1, filter, "string", "nil")
|
checkArg(1, filter, "string", "nil")
|
||||||
local t = component.list()
|
local t = component.list()
|
||||||
if not filter then return t end
|
local list = t
|
||||||
local list = {}
|
if filter then
|
||||||
|
list = {}
|
||||||
for addr, kind in pairs(t) do
|
for addr, kind in pairs(t) do
|
||||||
if type(exact) == "boolean" and exact then
|
if type(exact) == "boolean" and exact then
|
||||||
if kind == filter then
|
if kind == filter then
|
||||||
@ -159,6 +160,7 @@ libcomponent = {
|
|||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
end
|
||||||
|
|
||||||
local key = nil
|
local key = nil
|
||||||
return setmetatable(list, {
|
return setmetatable(list, {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user