Script that Implemented this callback has been destroyed

So basically, I’ve made a custom chassis system and it worked amazing for about 2-3 months but for some reason, it has a sudden error now.

Script that Implemented this callback has been destroyed
'Workspace.Lamborghini.DriverSeat.Script', Line 37 - function OnChildRemoved

The script:

function OnChildRemoved(child)
	if child:IsA("Weld") and (child.Part1.Name == "HumanoidRootPart") then
		local player = game.Players:GetPlayerFromCharacter(child.Part1.Parent)
		if player then
			if (player.PlayerGui:FindFirstChild("gui")) then
				player.PlayerGui.gui.stoooop:InvokeClient(player)
				player.PlayerGui.gui:Destroy()
			end
		end
	end	
end

Thing that confuses me is that it worked well about up until a week ago or so.
Thank you for your time :slight_smile: