diff --git a/src/loadSdk.js b/src/loadSdk.js index 1979e47..94ca83c 100644 --- a/src/loadSdk.js +++ b/src/loadSdk.js @@ -22,8 +22,7 @@ function loadSdk() { reject(new Error('Could not load YouTube SDK')); }; - const node = document.head || document.getElementsByTagName('head')[0]; - node.appendChild(script); + document.head.appendChild(script); }); }