i'm not following the if-else here - can you explain what's going on?