move the check mark to the inside of the if-test block