diff options
author | Matt A. Tobin <email@mattatobin.com> | 2020-07-27 19:18:35 -0400 |
---|---|---|
committer | Matt A. Tobin <email@mattatobin.com> | 2020-07-27 19:18:35 -0400 |
commit | 9ac440aa71abf4357acea2efee1a26904468ea62 (patch) | |
tree | 9bf1eb19ccb5b2ad60d9aca9e005852be87c6f05 /mailnews/base | |
parent | 39be34c06f9dc980a7ea11576365733fb83c342c (diff) | |
download | uxp-9ac440aa71abf4357acea2efee1a26904468ea62.tar.gz |
[MailNews] Allow setting "Local Folders" as always the first displayed account
Diffstat (limited to 'mailnews/base')
-rw-r--r-- | mailnews/base/util/folderUtils.jsm | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/mailnews/base/util/folderUtils.jsm b/mailnews/base/util/folderUtils.jsm index 9d2918a7a9..06e8e4bf2b 100644 --- a/mailnews/base/util/folderUtils.jsm +++ b/mailnews/base/util/folderUtils.jsm @@ -176,6 +176,10 @@ function allAccountsSorted(aExcludeIMAccounts) { accountList = accountList.sort(compareAccounts); } + // Set "Local Folders" as always the first displayed account + if (Services.prefs.getBoolPref("mail.accountmanager.localfolderfirst", false)) { + accountList.unshift(accountList.splice(accountList.findIndex(item => item.key === "account1"), 1)[0]); + } return accountList; } |