Skip to content

Commit

Permalink
Update JsBridgeExtOffscreen.ts (#168)
Browse files Browse the repository at this point in the history
  • Loading branch information
sidmorizon authored Apr 8, 2024
1 parent 747226f commit ca6a456
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ class JsBridgeExtOffscreen extends JsBridgeBase {
name: EXT_PORT_OFFSCREEN_TO_BG,
// #### background -> offscreen
onMessage: (payload: any, port0: chrome.runtime.Port) => {
let origin = utils.getOriginFromPort(port0) || '';
let origin = utils.getOriginFromPort(port0, { skipError: true }) || '';

// in ext offscreen, port.sender?.origin is always empty,
// so we trust remote (background) origin
Expand Down

0 comments on commit ca6a456

Please sign in to comment.