eslint 3.16.0 → 3.16.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md
CHANGED
@@ -1,3 +1,12 @@
|
|
1
|
+
v3.16.1 - February 22, 2017
|
2
|
+
|
3
|
+
* ff8a80c Fix: duplicated autofix output for inverted fix ranges (fixes #8116) (#8117) (Teddy Katz)
|
4
|
+
* a421897 Docs: fix typo in arrow-parens.md (#8132) (Will Chen)
|
5
|
+
* 22d7fbf Chore: fix invalid redeclared variables in tests (#8130) (Teddy Katz)
|
6
|
+
* 8d95598 Chore: fix output assertion typos in rule tests (#8129) (Teddy Katz)
|
7
|
+
* 9fa2559 Docs: Add missing quotes in key-spacing rule (#8121) (Glenn Reyes)
|
8
|
+
* f3a6ced Build: package.json update for eslint-config-eslint release (ESLint Jenkins)
|
9
|
+
|
1
10
|
v3.16.0 - February 20, 2017
|
2
11
|
|
3
12
|
* d89d0b4 Update: fix quotes false negative for string literals as template tags (#8107) (Teddy Katz)
|
@@ -188,6 +188,9 @@ module.exports = {
|
|
188
188
|
node,
|
189
189
|
loc: { line: openBrace.loc.start.line, column: openBrace.loc.start.column },
|
190
190
|
fix(fixer) {
|
191
|
+
|
192
|
+
// FIXME: The start of this range is sometimes larger than the end.
|
193
|
+
// https://github.com/eslint/eslint/issues/8116
|
191
194
|
return fixer.replaceTextRange([openBrace.end, nextToken.start - nextToken.loc.start.column], "\n");
|
192
195
|
},
|
193
196
|
message: NEVER_MESSAGE
|
@@ -108,7 +108,13 @@ SourceCodeFixer.applyFixes = function(sourceCode, messages) {
|
|
108
108
|
// Make output to this fix.
|
109
109
|
output += text.slice(Math.max(0, lastPos), Math.max(0, start));
|
110
110
|
output += fix.text;
|
111
|
-
|
111
|
+
|
112
|
+
/*
|
113
|
+
* If the start of the range is larger than the end for some reason, make sure
|
114
|
+
* the text between the end and the start doesn't get duplicated.
|
115
|
+
* https://github.com/eslint/eslint/issues/8116
|
116
|
+
*/
|
117
|
+
lastPos = Math.max(start, end);
|
112
118
|
}
|
113
119
|
output += text.slice(Math.max(0, lastPos));
|
114
120
|
|