check if a stage is selected before executing the task