We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent db6e7e6 commit 4f240ecCopy full SHA for 4f240ec
src/HTML5/Parser/Tokenizer.php
@@ -1181,16 +1181,11 @@ protected function decodeCharacterReference($inAttribute = false)
1181
return $entity;
1182
}
1183
1184
- // If in an attribute, then failing to match ; means unconsume the
1185
- // entire string. Otherwise, failure to match is an error.
1186
- if ($inAttribute) {
1187
- $this->scanner->unconsume($this->scanner->position() - $start);
1188
-
1189
- return '&';
1190
- }
+ // Failing to match ; means unconsume the entire string.
+ $this->scanner->unconsume($this->scanner->position() - $start);
1191
1192
$this->parseError('Expected &ENTITY;, got &ENTITY%s (no trailing ;) ', $tok);
1193
1194
- return '&' . $entity;
+ return '&';
1195
1196
0 commit comments