fix the conditional statement