better test for if values exist