Changed an unnecessary change in undefined check back to its original form.