My bad - read the if condition incorrectly,