Don't try to operate on an uninitialized drawer

This is necessary whenever the account list is configured as default
starting view.

Fixes #3716
This commit is contained in:
Marc K 2018-11-22 12:06:26 +01:00
parent 683b7d6eaf
commit 7f8894c8f9

View file

@ -1698,7 +1698,9 @@ public class MessageList extends K9Activity implements MessageListFragmentListen
List<String> folderServerIds = search.getFolderServerIds();
singleFolderMode = singleAccountMode && folderServerIds.size() == 1;
if (singleFolderMode) {
if (drawer == null) {
return;
} else if (singleFolderMode) {
drawer.selectFolder(folderServerIds.get(0));
} else if (search.getId().equals(SearchAccount.UNIFIED_INBOX)) {
drawer.selectUnifiedInbox();