delete extra closing tags