Skip to content

Commit

Permalink
Fix some small jslint issues
Browse files Browse the repository at this point in the history
  • Loading branch information
Marcin Szczepanski committed Jun 18, 2013
1 parent df00956 commit 844c8de
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/phantomjs/controller.js
Original file line number Diff line number Diff line change
Expand Up @@ -441,13 +441,13 @@ urls.forEach(function (url) {
delete this.prefs[name];
};
Preferences.prototype.getPrefList = function (branch_name, default_value) {
var list = {};
for (var key in this.prefs) {
var values = [], key;
for (key in this.prefs) {
if (this.prefs.hasOwnProperty(key) && key.indexOf(branch_name) === 0) {
list[key] = this.prefs[key];
values.push({ 'name': key, 'value': this.prefs[key] });
}
}
return list;
return values.length === 0 ? default_value : values;
};

return YSLOW.phantomjs.run();
Expand Down

0 comments on commit 844c8de

Please sign in to comment.