fix a bug with closing tag