Merge pull request #3586 from danren/KEYCLOAK-3961

Fix for KEYCLOAK-3961
This commit is contained in:
Stian Thorgersen 2016-12-02 13:52:01 +01:00 committed by GitHub
commit 2454b3b644

View file

@ -846,14 +846,15 @@
kc.clearToken();
}
for (var i = loginIframe.callbackList.length - 1; i >= 0; --i) {
var promise = loginIframe.callbackList[i];
var callbacks = loginIframe.callbackList.splice(0, loginIframe.callbackList.length);
for (var i = callbacks.length - 1; i >= 0; --i) {
var promise = callbacks[i];
if (event.data == "unchanged") {
promise.setSuccess();
} else {
promise.setError();
}
loginIframe.callbackList.splice(i, 1);
}
};