Change wait condition to make more sense