Replace a value in a table if nil?

I want to draw a list of friends from the server on my screen.

I’ll be adding them to a table, but I’m unsure how I could move a player up a slot if a friend disconnects.
I’ve done this before with tons of if statements. Is there a better way?

Tracking players is important; here’s a way you can do that ( you can even keep the data when they disconnect which would be useful for administration ).

Additionally, for players, instead of storing as a numbered auto-incrementing table.insert index, store them in a way that makes them easily findable.

These are good to read, thanks.

I didn’t know you could do things like this,

 local _name =; 

I’ll continue reading this later.