fixing minor issues in the code (deadcode issues)