check to see which part of the if statement is being executed