From c13b122a57b068eea88e537df03b216370f25132 Mon Sep 17 00:00:00 2001 From: Louis-Dominique Dubeau Date: Thu, 5 Jul 2018 14:33:37 -0400 Subject: [PATCH] fix: report an error on whitespace at the start of end tag --- lib/saxes.js | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) 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 {