check if var is not defined javascript