From 11d9a60a79c94d5b2650c8f19bf7a010d7956b82 Mon Sep 17 00:00:00 2001 From: CanadaHonk Date: Sun, 18 Dec 2022 12:32:30 +0000 Subject: [PATCH] launcher: fix IPC receiving --- src/launcher/inject.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/launcher/inject.js b/src/launcher/inject.js index e6b4bed..dbe9616 100644 --- a/src/launcher/inject.js +++ b/src/launcher/inject.js @@ -3,7 +3,7 @@ import IPCApi from '../lib/ipc.js'; export default async (CDP, injectionType = 'browser', { browserName }) => { let pageLoadCallback = () => {}, onWindowMessage = () => {}; CDP.onMessage(msg => { - if (msg.method === 'Runtime.bindingCalled' && msg.name === 'gluonSend') onWindowMessage(JSON.parse(msg.payload)); + if (msg.method === 'Runtime.bindingCalled' && msg.name === '_gluonSend') onWindowMessage(JSON.parse(msg.payload)); if (msg.method === 'Page.frameStoppedLoading') pageLoadCallback(msg.params); if (msg.method === 'Runtime.executionContextCreated') injectIPC(); // ensure IPC injection again });