Bug 1655400 - Enable ESLint rule no-setter-return for all of places. r=Standard8
Differential Revision: https://phabricator.services.mozilla.com/D85021
This commit is contained in:
@@ -955,12 +955,6 @@ module.exports = {
|
||||
"browser/components/downloads/content/indicator.js",
|
||||
"browser/components/payments/res/components/csc-input.js",
|
||||
"browser/components/payments/res/components/labelled-checkbox.js",
|
||||
"browser/components/places/content/browserPlacesViews.js",
|
||||
"browser/components/places/content/controller.js",
|
||||
"browser/components/places/content/places-menupopup.js",
|
||||
"browser/components/places/content/places-tree.js",
|
||||
"browser/components/places/content/places.js",
|
||||
"browser/components/places/content/treeView.js",
|
||||
"browser/components/pocket/content/Pocket.jsm",
|
||||
"browser/components/preferences/search.js",
|
||||
"browser/components/search/content/search-one-offs.js",
|
||||
@@ -984,7 +978,6 @@ module.exports = {
|
||||
"toolkit/components/extensions/ExtensionParent.jsm",
|
||||
"toolkit/components/osfile/modules/osfile_async_front.jsm",
|
||||
"toolkit/components/osfile/modules/osfile_shared_allthreads.jsm",
|
||||
"toolkit/components/places/PlacesExpiration.jsm",
|
||||
"toolkit/content/aboutSupport.js",
|
||||
"toolkit/content/customElements.js",
|
||||
"toolkit/content/preferencesBindings.js",
|
||||
|
||||
@@ -63,7 +63,6 @@ PlacesViewBase.prototype = {
|
||||
history.queryStringToQuery(val, query, options);
|
||||
let result = history.executeQuery(query.value, options.value);
|
||||
result.addObserver(this);
|
||||
return val;
|
||||
},
|
||||
|
||||
_result: null,
|
||||
@@ -72,7 +71,7 @@ PlacesViewBase.prototype = {
|
||||
},
|
||||
set result(val) {
|
||||
if (this._result == val) {
|
||||
return val;
|
||||
return;
|
||||
}
|
||||
|
||||
if (this._result) {
|
||||
@@ -97,8 +96,6 @@ PlacesViewBase.prototype = {
|
||||
this._resultNode = null;
|
||||
delete this._domNodes;
|
||||
}
|
||||
|
||||
return val;
|
||||
},
|
||||
|
||||
_options: null,
|
||||
@@ -114,8 +111,6 @@ PlacesViewBase.prototype = {
|
||||
val.extraClasses = {};
|
||||
}
|
||||
this._options = val;
|
||||
|
||||
return val;
|
||||
},
|
||||
|
||||
/**
|
||||
|
||||
@@ -46,7 +46,7 @@ function PlacesInsertionPoint({
|
||||
|
||||
PlacesInsertionPoint.prototype = {
|
||||
set index(val) {
|
||||
return (this._index = val);
|
||||
this._index = val;
|
||||
},
|
||||
|
||||
async getIndex() {
|
||||
@@ -1175,7 +1175,6 @@ PlacesController.prototype = {
|
||||
updateCutNodes(false);
|
||||
this._cutNodes = aNodes;
|
||||
updateCutNodes(true);
|
||||
return aNodes;
|
||||
},
|
||||
|
||||
/**
|
||||
|
||||
@@ -72,35 +72,35 @@
|
||||
return this._folder.elt;
|
||||
},
|
||||
set elt(val) {
|
||||
return (this._folder.elt = val);
|
||||
this._folder.elt = val;
|
||||
},
|
||||
|
||||
get openTimer() {
|
||||
return this._folder.openTimer;
|
||||
},
|
||||
set openTimer(val) {
|
||||
return (this._folder.openTimer = val);
|
||||
this._folder.openTimer = val;
|
||||
},
|
||||
|
||||
get hoverTime() {
|
||||
return this._folder.hoverTime;
|
||||
},
|
||||
set hoverTime(val) {
|
||||
return (this._folder.hoverTime = val);
|
||||
this._folder.hoverTime = val;
|
||||
},
|
||||
|
||||
get closeTimer() {
|
||||
return this._folder.closeTimer;
|
||||
},
|
||||
set closeTimer(val) {
|
||||
return (this._folder.closeTimer = val);
|
||||
this._folder.closeTimer = val;
|
||||
},
|
||||
|
||||
get closeMenuTimer() {
|
||||
return this._closeMenuTimer;
|
||||
},
|
||||
set closeMenuTimer(val) {
|
||||
return (this._closeMenuTimer = val);
|
||||
this._closeMenuTimer = val;
|
||||
},
|
||||
|
||||
setTimer: function OF__setTimer(aTime) {
|
||||
|
||||
@@ -150,7 +150,6 @@
|
||||
} else {
|
||||
this.removeAttribute("disableUserActions");
|
||||
}
|
||||
return val;
|
||||
}
|
||||
|
||||
get disableUserActions() {
|
||||
@@ -163,12 +162,11 @@
|
||||
// We save the view so that we can avoid expensive get calls when
|
||||
// we need to get the view again.
|
||||
this._view = val;
|
||||
/* eslint-disable no-undef */
|
||||
return Object.getOwnPropertyDescriptor(
|
||||
Object.getOwnPropertyDescriptor(
|
||||
// eslint-disable-next-line no-undef
|
||||
XULTreeElement.prototype,
|
||||
"view"
|
||||
).set.call(this, val);
|
||||
/* eslint-enable no-undef */
|
||||
}
|
||||
|
||||
get view() {
|
||||
@@ -188,7 +186,6 @@
|
||||
this.place = this.place;
|
||||
}
|
||||
}
|
||||
return val;
|
||||
}
|
||||
|
||||
get flatList() {
|
||||
@@ -215,8 +212,6 @@
|
||||
options = {};
|
||||
PlacesUtils.history.queryStringToQuery(val, query, options);
|
||||
this.load(query.value, options.value);
|
||||
|
||||
return val;
|
||||
}
|
||||
|
||||
get place() {
|
||||
@@ -409,7 +404,7 @@
|
||||
}
|
||||
|
||||
set active(val) {
|
||||
return (this._active = val);
|
||||
this._active = val;
|
||||
}
|
||||
|
||||
get active() {
|
||||
|
||||
@@ -277,7 +277,7 @@ var PlacesOrganizer = {
|
||||
|
||||
set location(aLocation) {
|
||||
if (!aLocation || this._location == aLocation) {
|
||||
return aLocation;
|
||||
return;
|
||||
}
|
||||
|
||||
if (this.location) {
|
||||
@@ -313,8 +313,6 @@ var PlacesOrganizer = {
|
||||
.getElementById("OrganizerCommand:Forward")
|
||||
.removeAttribute("disabled");
|
||||
}
|
||||
|
||||
return aLocation;
|
||||
},
|
||||
|
||||
_backHistory: [],
|
||||
@@ -838,7 +836,6 @@ var PlacesSearchBox = {
|
||||
},
|
||||
set folders(aFolders) {
|
||||
this._folders = aFolders;
|
||||
return aFolders;
|
||||
},
|
||||
|
||||
/**
|
||||
@@ -947,13 +944,11 @@ var PlacesSearchBox = {
|
||||
},
|
||||
set filterCollection(collectionName) {
|
||||
if (collectionName == this.filterCollection) {
|
||||
return collectionName;
|
||||
return;
|
||||
}
|
||||
|
||||
this.searchFilter.setAttribute("collection", collectionName);
|
||||
this.updateCollectionTitle();
|
||||
|
||||
return collectionName;
|
||||
},
|
||||
|
||||
/**
|
||||
@@ -977,7 +972,7 @@ var PlacesSearchBox = {
|
||||
return this.searchFilter.value;
|
||||
},
|
||||
set value(value) {
|
||||
return (this.searchFilter.value = value);
|
||||
this.searchFilter.value = value;
|
||||
},
|
||||
};
|
||||
|
||||
@@ -1380,7 +1375,6 @@ var ContentArea = {
|
||||
aNewView.associatedElement.focus();
|
||||
}
|
||||
}
|
||||
return aNewView;
|
||||
},
|
||||
|
||||
get currentPlace() {
|
||||
@@ -1396,7 +1390,6 @@ var ContentArea = {
|
||||
this._setupView();
|
||||
newView.active = true;
|
||||
}
|
||||
return aQueryString;
|
||||
},
|
||||
|
||||
/**
|
||||
|
||||
@@ -1210,8 +1210,6 @@ PlacesTreeView.prototype = {
|
||||
if (this._tree && val) {
|
||||
this._finishInit();
|
||||
}
|
||||
|
||||
return val;
|
||||
},
|
||||
|
||||
/**
|
||||
|
||||
@@ -759,7 +759,6 @@ nsPlacesExpiration.prototype = {
|
||||
// idle only if history is dirty, to preserve mobile devices batteries.
|
||||
this.expireOnIdle = aNewStatus == STATUS.DIRTY;
|
||||
}
|
||||
return aNewStatus;
|
||||
},
|
||||
get status() {
|
||||
return this._status;
|
||||
@@ -786,7 +785,6 @@ nsPlacesExpiration.prototype = {
|
||||
} else {
|
||||
this._expireOnIdle = aExpireOnIdle;
|
||||
}
|
||||
return this._expireOnIdle;
|
||||
},
|
||||
get expireOnIdle() {
|
||||
return this._expireOnIdle;
|
||||
|
||||
Reference in New Issue
Block a user