Skip to content

Commit

Permalink
[Fix] namespace: ensure this rule works in ES2018
Browse files Browse the repository at this point in the history
  • Loading branch information
ljharb committed Jun 24, 2018
1 parent add69cf commit 9db789b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/rules/namespace.js
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,7 @@ module.exports = {
if (pattern.type !== 'ObjectPattern') return

for (let property of pattern.properties) {
if (property.type === 'ExperimentalRestProperty') {
if (property.type === 'ExperimentalRestProperty' || !property.key) {
continue
}

Expand Down

0 comments on commit 9db789b

Please sign in to comment.