fix accidentally reverted condition