Um… Ok? I mean… I’ve given you some information to help you figure out how to implement it, are you wanting me to write it for you to? Because I’m not… I don’t believe in spoon-feeding people code just so they can copy-paste it… I don’t think anyone learns anything that way…
I’m not going to dive into your code (you don’t even have it on Github) just to figure out what this does so, I’ll ask you. What does this return when the player isn’t in the database? Does it return
nil or an empty table? If so, you can check that.
Also, I suggested that you move the checking to the server (since you can execute DB queries on here) so, do that (I’m saying this because this looks like it’s client-side code).