[Pkg-mozext-commits] [firetray] 60/84: cleaning

David Prévot taffit at moszumanska.debian.org
Sun Jul 20 01:42:46 UTC 2014


This is an automated email from the git hooks/post-receive script.

taffit pushed a commit to branch master
in repository firetray.

commit b49dac77db217c9dd9bc073ca31a4cfa5c6c8c29
Author: foudfou <foudil.newbie+git at gmail.com>
Date:   Sat May 24 16:04:27 2014 +0200

    cleaning
---
 src/chrome/content/overlay.js   |  2 +-
 src/modules/FiretrayHandler.jsm | 16 +++++++---------
 2 files changed, 8 insertions(+), 10 deletions(-)

diff --git a/src/chrome/content/overlay.js b/src/chrome/content/overlay.js
index 7f92236..3367f21 100644
--- a/src/chrome/content/overlay.js
+++ b/src/chrome/content/overlay.js
@@ -102,7 +102,7 @@ var firetrayChrome = { // each new window gets a new firetrayChrome !
   replaceCommand: function(eltId, func) {
     let elt = document.getElementById(eltId);
     if (!elt) {
-      firetray_log.info("Element '"+eltId+"' not found. Command not replaced.");
+      firetray_log.debug("Element '"+eltId+"' not found. Command not replaced.");
       return null;
     }
 
diff --git a/src/modules/FiretrayHandler.jsm b/src/modules/FiretrayHandler.jsm
index ab7d693..fd2bbdd 100644
--- a/src/modules/FiretrayHandler.jsm
+++ b/src/modules/FiretrayHandler.jsm
@@ -502,23 +502,21 @@ firetray.Handler = {
      branch: "mail.biff.", pref: "show_tray_icon", bak:null}
   ],
   disablePrefsTmp: function() {
-    for (let i=0, len=this.prefsDisable.length; i<len; ++i) {
-      let pref = this.prefsDisable[i];
-      if (!pref.cond()) continue;
+    this.prefsDisable.forEach(function(pref){
+      if (!pref.cond()) return;
       let branch = Services.prefs.getBranch(pref.branch);
       pref.bak = branch.getBoolPref(pref.pref);
-      log.debug(pref.pref+" saved. was: "+pref.bak);
+      log.warn(pref.pref+" saved. was: "+pref.bak);
       branch.setBoolPref(pref.pref, false);
-    }
+    });
   },
   restorePrefsTmp: function() {
-    for (let i=0, len=this.prefsDisable.length; i<len; ++i) {
-      let pref = this.prefsDisable[i];
-      if (!pref.cond() || !pref.bak) continue;
+    this.prefsDisable.forEach(function(pref){
+      if (!pref.cond() || !pref.bak) return;
       let branch = Services.prefs.getBranch(pref.branch);
       branch.setBoolPref(pref.pref, pref.bak);
       log.debug(pref.pref+" restored to: "+pref.bak);
-    }
+    });
   }
 
 }; // firetray.Handler

-- 
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