diff options
author | Matěj Cepl <mcepl@redhat.com> | 2010-09-19 00:34:48 +0200 |
---|---|---|
committer | Matěj Cepl <mcepl@redhat.com> | 2010-09-19 00:34:48 +0200 |
commit | c2a09508ae88149e615bd8f393858dd927f491cf (patch) | |
tree | a7be1ef25ebb4266f63bd3fc4e07ec02a166b0b2 /lib/bzpage.js | |
parent | 88112016166ac10e7ed2848c9562bed211918748 (diff) | |
download | bugzilla-triage-c2a09508ae88149e615bd8f393858dd927f491cf.tar.gz |
Fix .split() method
Diffstat (limited to 'lib/bzpage.js')
-rw-r--r-- | lib/bzpage.js | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/bzpage.js b/lib/bzpage.js index 96ad655..2278209 100644 --- a/lib/bzpage.js +++ b/lib/bzpage.js @@ -177,10 +177,10 @@ BZPage.prototype.getInstalledPackages = function getInstalledPackages(cfg) { if ("enabledPackages" in cfg.gJSONData.configData) { var epObject = cfg.gJSONData.configData.enabledPackages; if (this.hostname in epObject) { - enabledPackages = enabledPackages.concat(epObject[this.hostname].split(/[, ]/)); + enabledPackages = enabledPackages.concat(epObject[this.hostname].split(/[,\s]+/)); } if ("any" in epObject) { - enabledPackages = enabledPackages.concat(epObject.any.split(/[, ]/)); + enabledPackages = enabledPackages.concat(epObject.any.split(/[,\s]+/)); } } @@ -739,7 +739,7 @@ BZPage.prototype.idContainsWord = function idContainsWord (id, str) { // For those who don't have particular element at all or if it is empty return false; } - return (util.isInList(str, kwd.trim().split(/,\s*/))); + return (util.isInList(str, kwd.trim().split(/[,\s]+/))); }; /** |