Skip to content

Commit

Permalink
chore: improve formatting of namespace hint
Browse files Browse the repository at this point in the history
  • Loading branch information
nikku authored and fake-join[bot] committed Jan 10, 2023
1 parent 46523dc commit d1b11f5
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions lib/write.js
Original file line number Diff line number Diff line change
Expand Up @@ -500,12 +500,13 @@ ElementSerializer.prototype.parseGenericAttributes = function(element, attribute
try {
self.addAttribute(self.nsAttributeName(attr.name), attr.value);
} catch (e) {
/* global console */

console.warn(
'missing namespace information for ',
attr.name, '=', attr.value, 'on', element,
e);
// eslint-disable-next-line no-undef
typeof console !== 'undefined' && console.warn(
`missing namespace information for <${
attr.name
}=${ attr.value }> on`, element, e
);
}
});
};
Expand Down

0 comments on commit d1b11f5

Please sign in to comment.