Clean up the if statement