game.Players.PlayerRemoving:connect(function(player)
local bob=player.Name
for i,v in pairs (workspace.Population.Worker.bob:GetChildren()) do
v.Parent=workspace.Population.Unemployed
workspace.Population.Worker.bob:Destroy()
end
end)
The reason I am using a variable is because bob is supposed to be the name of a player and I want to make it so that bob will have all its children become unemployed and the model itself to be destroyed but it keeps saying bob is not a valid member of model.

2 comments
Line 5 should also be [bob].
o yes. thx