mirror of
https://git.anonymousland.org/anonymousland/synapse-product.git
synced 2024-12-17 18:44:21 -05:00
window.postmessage for Interactive Auth fallback
If you're a webapp running the fallback in an iframe, you can't set set a window.onAuthDone function. Let's post a message back to window.opener instead.
This commit is contained in:
parent
36d621201b
commit
f382117852
@ -77,8 +77,10 @@ SUCCESS_TEMPLATE = """
|
||||
user-scalable=no, minimum-scale=1.0, maximum-scale=1.0'>
|
||||
<link rel="stylesheet" href="/_matrix/static/client/register/style.css">
|
||||
<script>
|
||||
if (window.onAuthDone != undefined) {
|
||||
if (window.onAuthDone) {
|
||||
window.onAuthDone();
|
||||
} else if (window.opener && window.opener.postMessage) {
|
||||
window.opener.postMessage("authDone", "*");
|
||||
}
|
||||
</script>
|
||||
</head>
|
||||
|
Loading…
Reference in New Issue
Block a user