throw error instead of warning when two attributes with the same name are defined in the body.

This commit is contained in:
Netanel Gilad
2015-01-18 22:31:39 +02:00
committed by Sashko Stubailo
parent fa4e9c676e
commit d49af044d2

View File

@@ -174,7 +174,7 @@ html_scanner = {
if (hasAttribs) {
for(var attr in attribs) {
if (this.bodyAttributes.indexOf(attr) !== -1) {
console.log('WARNING: tag ' + attr + ' already defined on body.');
throwParseError('Tag ' + attr + ' already defined on body.');
}
this.bodyAttributes.push(attr);
}