File tree Expand file tree Collapse file tree 1 file changed +2
-1
lines changed
packages/happy-dom/src/nodes/html-link-element Expand file tree Collapse file tree 1 file changed +2
-1
lines changed Original file line number Diff line number Diff line change @@ -334,7 +334,6 @@ export default class HTMLLinkElement extends HTMLElement {
334
334
async #preloadResource( url : string ) : Promise < void > {
335
335
const window = this [ PropertySymbol . window ] ;
336
336
const browserFrame = new WindowBrowserContext ( window ) . getBrowserFrame ( ) ;
337
- const browserSettings = browserFrame . page ?. context ?. browser ?. settings ;
338
337
const as = this . as ;
339
338
340
339
// Only "script", "style" and "fetch" are supported for now.
@@ -346,6 +345,8 @@ export default class HTMLLinkElement extends HTMLElement {
346
345
return ;
347
346
}
348
347
348
+ const browserSettings = browserFrame . page ?. context ?. browser ?. settings ;
349
+
349
350
if (
350
351
as === 'script' &&
351
352
( browserSettings . disableJavaScriptFileLoading || browserSettings . disableJavaScriptEvaluation )
You can’t perform that action at this time.
0 commit comments