diff --git a/lib/saxes.js b/lib/saxes.js index e1c0143e..3c39cab8 100644 --- a/lib/saxes.js +++ b/lib/saxes.js @@ -719,10 +719,7 @@ class SAXParser { case S_CLOSE_TAG: if (!this.tagName) { - if (isWhitespace(c)) { - continue; - } - else if (notMatch(NAME_START_CHAR, c)) { + if (notMatch(NAME_START_CHAR, c)) { this.fail("Invalid tagname in closing tag."); } else {