fix next button display condition