diff --git a/app/app.js b/app/app.js index e9db17855..7d989c435 100644 --- a/app/app.js +++ b/app/app.js @@ -76,6 +76,7 @@ export default class App { return Initialization.credentials; }, () => { + this.waitForRehydration = true; return getGenericPassword(); } ); @@ -153,6 +154,13 @@ export default class App { } const username = `${deviceToken}, ${currentUserId}`; const password = `${token},${url}`; + + if (this.waitForRehydration) { + this.waitForRehydration = false; + this.token = token; + this.url = url; + } + setGenericPassword(username, password); }; @@ -215,7 +223,7 @@ export default class App { }; startApp = () => { - if (this.appStarted) { + if (this.appStarted || this.waitForRehydration) { return; }