[Pkg-mozext-commits] [firetray] 229/399: fix cleanExcludedAccounts()
David Prévot
taffit at alioth.debian.org
Tue Oct 29 18:23:48 UTC 2013
This is an automated email from the git hooks/post-receive script.
taffit pushed a commit to branch dfsg-clean
in repository firetray.
commit 8d0917ab628f5f8fe615e4f8fdb126f804efd2ca
Author: foudfou <foudil.newbie+git at gmail.com>
Date: Sat Apr 21 16:15:43 2012 +0200
fix cleanExcludedAccounts()
---
src/modules/FiretrayMessaging.jsm | 8 +++-----
1 file changed, 3 insertions(+), 5 deletions(-)
diff --git a/src/modules/FiretrayMessaging.jsm b/src/modules/FiretrayMessaging.jsm
index a4687db..f7dddb8 100644
--- a/src/modules/FiretrayMessaging.jsm
+++ b/src/modules/FiretrayMessaging.jsm
@@ -61,7 +61,6 @@ firetray.Messaging = {
/* removes removed accounts from excludedAccounts pref. NOTE: Can't be called
at shutdown because MailServices.accounts no longer available */
cleanExcludedAccounts: function() {
- try {
F.LOG("* cleaning *");
let mailAccounts = firetray.Utils.getObjPref('mail_accounts');
let excludedAccounts = mailAccounts["excludedAccounts"];
@@ -71,12 +70,12 @@ firetray.Messaging = {
let accountServerKeys = [];
for (let i=0, len=accounts.Count(); i<len; ++i) {
let account = accounts.QueryElementAt(i, Ci.nsIMsgAccount);
- let accountServer = account.incomingServer;
- accountServerKeys[i] = accountServer;
+ accountServerKeys[i] = account.incomingServer.key;
}
let newExcludedAccounts = [], cleaningNeeded = 0;
- for (let excludedAccount in excludedAccounts) {
+ for (let i=0, len=excludedAccounts.length; i<len; ++i) {
+ let excludedAccount = excludedAccounts[i];
if (accountServerKeys.indexOf(excludedAccount) >= 0)
newExcludedAccounts.push(excludedAccount);
else
@@ -88,7 +87,6 @@ firetray.Messaging = {
let prefObj = {"serverTypes":mailAccounts["serverTypes"], "excludedAccounts":newExcludedAccounts};
firetray.Utils.setObjPref('mail_accounts', prefObj);
}
- } catch(x) { F.ERROR(x); }
},
/* http://mxr.mozilla.org/comm-central/source/mailnews/base/public/nsIFolderListener.idl */
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-mozext/firetray.git
More information about the Pkg-mozext-commits
mailing list