Skip to content

Commit

Permalink
Merge pull request #244 from magento-commerce/imported-fredden-magent…
Browse files Browse the repository at this point in the history
…o-coding-standard-358

[Imported] [eslint] Enforce consistent indentation
  • Loading branch information
sidolov authored Sep 20, 2023
2 parents dccf910 + 83ddd30 commit 60be03f
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 12 deletions.
1 change: 1 addition & 0 deletions eslint/.eslintrc-magento
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
"eol-last": 2,
"eqeqeq": [2, "smart"],
"guard-for-in": 2,
"indent": [2, 4],
"keyword-spacing": [2, {}],
"lines-around-comment": [
2,
Expand Down
24 changes: 12 additions & 12 deletions eslint/rules/utils.js
Original file line number Diff line number Diff line change
Expand Up @@ -75,18 +75,18 @@ function getExpressionId(node) {

while (node) {
switch (node.type) {
case 'CallExpression':
node = node.callee;
break;

case 'MemberExpression':
node = node.object;
break;

case 'Identifier':
return node;
default:
return null;
case 'CallExpression':
node = node.callee;
break;

case 'MemberExpression':
node = node.object;
break;

case 'Identifier':
return node;
default:
return null;
}
}
}
Expand Down

0 comments on commit 60be03f

Please sign in to comment.