[MM-39310] Add setTimeout to new server modal pop to make sure it renders correctly. (#1811) (#1815)

(cherry picked from commit 6ae15b0cea)

Co-authored-by: Devin Binnie <52460000+devinbinnie@users.noreply.github.com>
This commit is contained in:
Mattermost Build 2021-10-14 23:20:17 +02:00 committed by GitHub
parent 8596e1ec87
commit 41ae49009e
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -718,13 +718,6 @@ function initializeAfterAppReady() {
WindowManager.showMainWindow(deeplinkingURL);
// only check for non-Windows, as with Windows we have to wait for GPO teams
if (process.platform !== 'win32' || typeof config.registryConfigData !== 'undefined') {
if (config.teams.length === 0) {
handleNewServerModal();
}
}
criticalErrorHandler.setMainWindow(WindowManager.getMainWindow()!);
// listen for status updates and pass on to renderer
@ -797,6 +790,15 @@ function initializeAfterAppReady() {
// is the requesting url trusted?
callback(urlUtils.isTrustedURL(requestingURL, config.teams));
});
// only check for non-Windows, as with Windows we have to wait for GPO teams
if (process.platform !== 'win32' || typeof config.registryConfigData !== 'undefined') {
if (config.teams.length === 0) {
setTimeout(() => {
handleNewServerModal();
}, 200);
}
}
}
//