mirror of
https://github.com/moparisthebest/mail
synced 2025-01-10 21:18:02 -05:00
[WO-429] Set account.online after setting imap cache to prevent race condition
This commit is contained in:
parent
af0ae907c9
commit
9465ce57ed
@ -965,9 +965,6 @@ define(function(require) {
|
||||
return;
|
||||
}
|
||||
|
||||
// set status to online
|
||||
self._account.online = true;
|
||||
|
||||
// init folders
|
||||
self._initFolders(function(err) {
|
||||
if (err) {
|
||||
@ -1009,6 +1006,9 @@ define(function(require) {
|
||||
});
|
||||
self._imapClient.mailboxCache = mailboxCache;
|
||||
|
||||
// set status to online after setting cache to prevent race condition
|
||||
self._account.online = true;
|
||||
|
||||
// set up the imap client to listen for changes in the inbox
|
||||
var inbox = _.findWhere(self._account.folders, {
|
||||
type: 'Inbox'
|
||||
|
Loading…
Reference in New Issue
Block a user