Skip to content

Commit

Permalink
Fix bad timer name (#2821)
Browse files Browse the repository at this point in the history
Account for self.data not existing in timer
  • Loading branch information
Denneisk authored Oct 31, 2023
1 parent be75c7d commit d9a46cc
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lua/entities/gmod_wire_expression2/core/selfaware.lua
Original file line number Diff line number Diff line change
Expand Up @@ -109,8 +109,8 @@ local function doSetName(self, this, name)
if totalChars >= 512 then return self:throw("You are sending too much data with setName!") end
data_SetName._chars = totalChars

timer.Create("wire_doSetName_Cleanup", 1, 1, function()
self.data.SetName = nil
timer.Create("wire_doSetName_Cleanup" .. self.entity:EntIndex(), 1, 1, function()
if self and self.data then self.data.SetName = nil end
end)

if this:GetClass() == "gmod_wire_expression2" then
Expand Down

0 comments on commit d9a46cc

Please sign in to comment.