Skip to content

Commit 2ef100c

Browse files
committed
Fixed more eslint issues
1 parent 4ec71f8 commit 2ef100c

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

lib/rules/jsx-indent.js

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -168,18 +168,20 @@ module.exports = {
168168
* @return {Number} Indent
169169
*/
170170
function getNodeIndent(node, byLastLine, excludeCommas) {
171-
byLastLine = byLastLine || false;
172-
excludeCommas = excludeCommas || false;
171+
let finalLine = byLastLine;
172+
let noCommas = excludeCommas;
173+
finalLine = finalLine || false;
174+
noCommas = noCommas || false;
173175

174176
let src = context.getSourceCode().getText(node, node.loc.start.column + extraColumnStart);
175177
const lines = src.split('\n');
176-
if (byLastLine) {
178+
if (finalLine) {
177179
src = lines[lines.length - 1];
178180
} else {
179181
src = lines[0];
180182
}
181183

182-
const skip = excludeCommas ? ',' : '';
184+
const skip = noCommas ? ',' : '';
183185

184186
let regExp;
185187
if (indentType === 'space') {

0 commit comments

Comments
 (0)