Run eslint --fix
Fixing 1000s of lint issues. Some rules cannot be `--fix`ed but this goes some way to linting the entire codebase.
This commit is contained in:
parent
8958be9321
commit
d3f9a3aeb5
136 changed files with 2540 additions and 2657 deletions
|
@ -29,9 +29,9 @@ module.exports = function(f, minIntervalMs) {
|
|||
this.lastCall = 0;
|
||||
this.scheduledCall = undefined;
|
||||
|
||||
var self = this;
|
||||
var wrapper = function() {
|
||||
var now = Date.now();
|
||||
const self = this;
|
||||
const wrapper = function() {
|
||||
const now = Date.now();
|
||||
|
||||
if (self.lastCall < now - minIntervalMs) {
|
||||
f.apply(this);
|
||||
|
@ -43,7 +43,7 @@ module.exports = function(f, minIntervalMs) {
|
|||
f.apply(this);
|
||||
self.lastCall = now;
|
||||
},
|
||||
(self.lastCall + minIntervalMs) - now
|
||||
(self.lastCall + minIntervalMs) - now,
|
||||
);
|
||||
}
|
||||
};
|
||||
|
@ -58,9 +58,9 @@ module.exports = function(f, minIntervalMs) {
|
|||
|
||||
// make sure that cancelPendingCall is copied when react rebinds the
|
||||
// wrapper
|
||||
var _bind = wrapper.bind;
|
||||
const _bind = wrapper.bind;
|
||||
wrapper.bind = function() {
|
||||
var rebound = _bind.apply(this, arguments);
|
||||
const rebound = _bind.apply(this, arguments);
|
||||
rebound.cancelPendingCall = wrapper.cancelPendingCall;
|
||||
return rebound;
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue