check if value exists in array