Fix resample condition.