You've already forked matrix-js-sdk
mirror of
https://github.com/matrix-org/matrix-js-sdk.git
synced 2025-11-25 05:23:13 +03:00
Update ESLint
* Bump version * Add a couple of rules to match our existing precedent * Fix a few genuine lint errors * Ignore a guard-for-in (not sure why eslint doesn't like this?) * Update max warnings
This commit is contained in:
@@ -330,7 +330,7 @@ const deepCompare = module.exports.deepCompare = function(x, y) {
|
||||
}
|
||||
|
||||
// finally, compare each of x's keys with y
|
||||
for (p in y) {
|
||||
for (p in y) { // eslint-disable-line guard-for-in
|
||||
if (y.hasOwnProperty(p) !== x.hasOwnProperty(p)) {
|
||||
return false;
|
||||
}
|
||||
@@ -693,7 +693,7 @@ module.exports.globToRegexp = function(glob, extended) {
|
||||
if (extended) {
|
||||
pat = pat.replace(/\\\[(!|)(.*)\\]/g, function(match, p1, p2, offset, string) {
|
||||
const first = p1 && '^' || '';
|
||||
const second = p2.replace(/\\\-/, '-');
|
||||
const second = p2.replace(/\\-/, '-');
|
||||
return '[' + first + second + ']';
|
||||
});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user