Fix dead code scenario.

Changes explained