feat(es_extended/shared/modules/table): add ESX.Table.Wipe

This commit is contained in:
Kenshin13
2025-01-05 17:40:42 +01:00
parent 81b040d949
commit 13b44b5aa0
+10 -2
View File
@@ -224,10 +224,18 @@ function ESX.Table.Sort(t, order)
end end
end end
function ESX.Table.ToArray(table) ---@param t table
---@return Array
function ESX.Table.ToArray(t)
local array = {} local array = {}
for _, v in pairs(table) do for _, v in pairs(t) do
array[#array + 1] = v array[#array + 1] = v
end end
return array return array
end end
---@param t table
---@return table
function ESX.Table.Wipe(t)
return table.wipe(t)
end