aboutsummaryrefslogtreecommitdiffstats
path: root/lib/bzpage.js
diff options
context:
space:
mode:
Diffstat (limited to 'lib/bzpage.js')
-rw-r--r--lib/bzpage.js10
1 files changed, 9 insertions, 1 deletions
diff --git a/lib/bzpage.js b/lib/bzpage.js
index eac54af..14dde0e 100644
--- a/lib/bzpage.js
+++ b/lib/bzpage.js
@@ -105,7 +105,15 @@ BZPage.prototype.getInstalledPackages = function getInstalledPackages(cfg) {
if (preferences.isSet(prefName)) {
enabledPackages = preferences.get(prefName,"").split(/[, ]/);
} else {
- preferences.set(prefName,"");
+ console.log("Setting default preference " + prefName + " to 'all'.");
+ preferences.set(prefName,"all");
+ }
+
+ if ((enabledPackages.length === 1) && (enabledPackages[0] === "all")) {
+ enabledPackages = [];
+ for (var key in cfg.gJSONData.commentPackages) {
+ enabledPackages.push(key);
+ }
}
enabledPackages.forEach(function (pkg, idx, arr) {