fix: improve external script plugin (#632)

This commit is contained in:
slengyel-lnx 2018-10-23 09:58:24 +03:00 committed by cinwell.li
commit 50c2434ab5
2 changed files with 2 additions and 2 deletions

View file

@ -10,7 +10,7 @@ function handleExternalScript() {
var newScript = document.createElement('script');
Array.prototype.slice.call(script.attributes).forEach(function (attribute) {
newScript[attribute.name] = attribute.value;
newScript.setAttribute(attribute.name, attribute.value);
});
script.parentNode.insertBefore(newScript, script);