diff options
author | cjihrig <cjihrig@gmail.com> | 2019-03-01 21:47:17 -0500 |
---|---|---|
committer | cjihrig <cjihrig@gmail.com> | 2019-03-03 22:04:24 -0500 |
commit | 17b7fa75c345ec2ef59c489a33aa14f346d60dc5 (patch) | |
tree | d16f47fc4bdafa0db5a450b44e65a64dbbc3756c /tools/node_modules/eslint/lib/rules/max-len.js | |
parent | 8c597df3502c26fba74c966168376c818b61b73b (diff) | |
download | android-node-v8-17b7fa75c345ec2ef59c489a33aa14f346d60dc5.tar.gz android-node-v8-17b7fa75c345ec2ef59c489a33aa14f346d60dc5.tar.bz2 android-node-v8-17b7fa75c345ec2ef59c489a33aa14f346d60dc5.zip |
tools: update ESLint to 5.15.0
Update ESLint to 5.15.0
PR-URL: https://github.com/nodejs/node/pull/26391
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Masashi Hirano <shisama07@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Diffstat (limited to 'tools/node_modules/eslint/lib/rules/max-len.js')
-rw-r--r-- | tools/node_modules/eslint/lib/rules/max-len.js | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/tools/node_modules/eslint/lib/rules/max-len.js b/tools/node_modules/eslint/lib/rules/max-len.js index f6f0b6d3ac..6e7dd6f1ac 100644 --- a/tools/node_modules/eslint/lib/rules/max-len.js +++ b/tools/node_modules/eslint/lib/rules/max-len.js @@ -103,7 +103,7 @@ module.exports = { * too many false positives * - We don't care about matching the entire URL, any small segment is fine */ - const URL_REGEXP = /[^:/?#]:\/\/[^?#]/; + const URL_REGEXP = /[^:/?#]:\/\/[^?#]/u; const sourceCode = context.getSourceCode(); @@ -118,7 +118,7 @@ module.exports = { function computeLineLength(line, tabWidth) { let extraCharacterCount = 0; - line.replace(/\t/g, (match, offset) => { + line.replace(/\t/gu, (match, offset) => { const totalOffset = offset + extraCharacterCount, previousTabStopOffset = tabWidth ? totalOffset % tabWidth : 0, spaceCount = tabWidth - previousTabStopOffset; @@ -153,7 +153,7 @@ module.exports = { let ignorePattern = options.ignorePattern || null; if (ignorePattern) { - ignorePattern = new RegExp(ignorePattern); + ignorePattern = new RegExp(ignorePattern); // eslint-disable-line require-unicode-regexp } //-------------------------------------------------------------------------- @@ -201,7 +201,7 @@ module.exports = { function stripTrailingComment(line, comment) { // loc.column is zero-indexed - return line.slice(0, comment.loc.start.column).replace(/\s+$/, ""); + return line.slice(0, comment.loc.start.column).replace(/\s+$/u, ""); } /** |