@@ -269,12 +269,9 @@ export class IframeSandbox implements SignalSandbox {
269
269
270
270
void window . addEventListener ( 'message' , ( e ) => {
271
271
if ( e . source === this . iframe . contentWindow && e . data === 'iframe_ready' ) {
272
- this . iframe . contentWindow ! . postMessage (
273
- {
274
- type : 'init' ,
275
- } ,
276
- '*'
277
- )
272
+ this . iframe . contentWindow ! . postMessage ( {
273
+ type : 'init' ,
274
+ } )
278
275
this . _resolveReady ( )
279
276
}
280
277
} )
@@ -304,10 +301,10 @@ export class IframeSandbox implements SignalSandbox {
304
301
const signalsScript = document.getElementById('edge-fn')
305
302
if (typeof processSignal === 'undefined') {
306
303
signalsScript.onload = () => {
307
- window.parent.postMessage('iframe_ready', '*' )
304
+ window.parent.postMessage('iframe_ready')
308
305
}
309
306
} else {
310
- window.parent.postMessage('iframe_ready', '*' )
307
+ window.parent.postMessage('iframe_ready')
311
308
}
312
309
313
310
class AnalyticsRuntimeProxy {
@@ -364,9 +361,9 @@ export class IframeSandbox implements SignalSandbox {
364
361
});
365
362
window.signals.signalBuffer = signalBuffer; // signals is exposed as part of get runtimeCode
366
363
window.processSignal(signal, { signals, constants })
367
- event.source.postMessage({ type: 'execution_result', payload: analyticsProxy.getCalls() }, '*' );
364
+ event.source.postMessage({ type: 'execution_result', payload: analyticsProxy.getCalls() });
368
365
} catch(err) {
369
- event.source.postMessage({ type: 'execution_error', error: err }, '*' );
366
+ event.source.postMessage({ type: 'execution_error', error: err });
370
367
}
371
368
}
372
369
});
@@ -417,17 +414,14 @@ export class IframeSandbox implements SignalSandbox {
417
414
418
415
window . addEventListener ( 'message' , handler )
419
416
420
- this . iframe . contentWindow ! . postMessage (
421
- {
422
- type : 'execute' ,
423
- payload : {
424
- signal,
425
- signalBuffer : signals ,
426
- constants : WebRuntimeConstants ,
427
- } ,
417
+ this . iframe . contentWindow ! . postMessage ( {
418
+ type : 'execute' ,
419
+ payload : {
420
+ signal,
421
+ signalBuffer : signals ,
422
+ constants : WebRuntimeConstants ,
428
423
} ,
429
- '*'
430
- )
424
+ } )
431
425
} )
432
426
}
433
427
0 commit comments