Private Server Code Issue

i am having a problem with my private server code script

the problem is that the code that is used to teleport the player doesnt work
here is a sc of how the data is stored:

1st is the generated code that player enters to join a server
2nd is the owners id
3rd is time created
4th is the return of ReserveServer()

when i try to teleport the player with the 4th code it says that the place is restricted place is public but when i teleport the player right after i generate the reservecode it teleports fine i am using normal datastore not global can anyone tell me whats the problem it may be stupid i havent been able to figure it out for few hours so if anyone knows why please tell me