Keep legacy allowMainWorld behavior

This commit is contained in:
daijro 2025-02-03 22:54:21 -06:00
parent cf269d6b60
commit 5ec48fdbe6

View file

@ -546,7 +546,7 @@ class Frame {
}); });
// Camoufox: Create a main world for the isolated context // Camoufox: Create a main world for the isolated context
if (this.allowMW) { if (this.allowMW) {
const mainWorld = this._runtime.createMW(this.domWindow(), sandbox); const mainWorld = this._runtime.createMW(this.domWindow(), this.domWindow());
world.mainEquivalent = mainWorld; world.mainEquivalent = mainWorld;
} }
this._worldNameToContext.set(name, world); this._worldNameToContext.set(name, world);