Sv443 hai 1 ano
pai
achega
2c2a765891
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      src/utils.ts

+ 1 - 1
src/utils.ts

@@ -122,7 +122,7 @@ export function addGlobalStyle(style: string, ref?: string) {
   const styleElem = document.createElement("style");
   styleElem.id = `betterytm-style-${ref}`;
   styleElem.innerHTML = style;
-  document.querySelector("head")!.appendChild(styleElem);
+  document.head.appendChild(styleElem);
 
   dbg && console.log(`BetterYTM: Inserted global style with ref '${ref}':`, styleElem);
 }