javascript check if variable not empty