cleaning tags code