mirror of
https://github.com/ACF-Team/CFW.git
synced 2025-03-04 03:03:16 -05:00
Added an extra check to ENT:GetLinks()
- In some cases, you could use ENT:GetLinks() on entities that were never linked before, now we'll make sure that's the case before copying that table.
This commit is contained in:
parent
2aafe1b6b6
commit
0a31f7e20c
@ -89,10 +89,13 @@ do
|
||||
end
|
||||
|
||||
function ENT:GetLinks() -- Creates a shallow copy of the links table
|
||||
local out = {}
|
||||
local links = self._links
|
||||
local out = {}
|
||||
|
||||
for k, v in pairs(self._links) do
|
||||
out[k] = v
|
||||
if links then
|
||||
for k, v in pairs(links) do
|
||||
out[k] = v
|
||||
end
|
||||
end
|
||||
|
||||
return out
|
||||
|
Loading…
Reference in New Issue
Block a user