fix(editor): Use BroadcastChannel instead of window.opener for OAuth callback window (#9779)

This commit is contained in:
कारतोफ्फेलस्क्रिप्ट™
2024-06-17 13:41:49 +02:00
committed by GitHub
parent a1046607bf
commit 87cb199745
6 changed files with 68 additions and 12 deletions

View File

@@ -17,7 +17,10 @@
{{/if}}
Failed to connect. The window can be closed now.
<script>
(function messageParent() { window.opener?.postMessage('error', '*'); })();
(function messageParent() {
const broadcastChannel = new BroadcastChannel('oauth-callback');
broadcastChannel.postMessage('error');
})();
</script>
</body>
</html>