optimize condition to skip