[Component-DI] Removed useless else statement in code example