Fix bug when editing start tag