mirror of
https://github.com/M66B/FairEmail.git
synced 2025-03-03 10:16:45 +00:00
Prevent crash
This commit is contained in:
parent
b4742a2072
commit
f667d17a83
1 changed files with 6 additions and 5 deletions
|
@ -242,14 +242,15 @@ public class ServiceUI extends IntentService {
|
|||
Log.i("Synchronize on demand folder=" + fid);
|
||||
|
||||
DB db = DB.getInstance(this);
|
||||
EntityFolder folder = null;
|
||||
EntityAccount account = null;
|
||||
EntityFolder folder = db.folder().getFolder(fid);
|
||||
if (folder == null)
|
||||
return;
|
||||
EntityAccount account = db.account().getAccount(folder.account);
|
||||
if (account == null)
|
||||
return;
|
||||
|
||||
Store istore = null;
|
||||
try {
|
||||
folder = db.folder().getFolder(fid);
|
||||
account = db.account().getAccount(folder.account);
|
||||
|
||||
// Create session
|
||||
Properties props = MessageHelper.getSessionProperties(account.auth_type, account.realm, account.insecure);
|
||||
final Session isession = Session.getInstance(props, null);
|
||||
|
|
Loading…
Reference in a new issue