Fix race conditions that could prevent applications from being loaded

This commit is contained in:
yflory committed 2016-10-05 11:19:18 +02:00
1 parent 7d5a33512a
commit 74df38f94f
2 files changed
+26 -9

No files matched your search

+14 -1
View File
@@ -557,7 +557,20 @@ define([
Store.ready(function (err, store) {
common.store = env.store = store;
cb();
$(function() {
if($('#pad-iframe').length) {
var $iframe = $('#pad-iframe');
var iframe = $iframe[0];
var iframeDoc = iframe.contentDocument || iframe.contentWindow.document;
if (iframeDoc.readyState === 'complete') {
cb();
return;
}
$iframe.load(cb);
return;
}
cb();
});
return;
/*
authorize(function (err, proxy) {