SharedObject data check?

Hi i am currently designing a game where when the user starts the game they enter thier name and press continue, thier name is then stored in a ShredObject by this command “localInfo.data.user = name;”, and if the player wins or loses they get the chance to play again. basicaly i want to check at the start of the game if a value exists within the “localInfo.data.user” and if it does i dont want to display the box for the user to enter thier name as it already exists. But i dont know how to do this i tried the below statement but it didnt work i would really appreciate any help:

if(localInfo.data.user == false)
{

}