Update tag and remove unused code