File tree Expand file tree Collapse file tree 1 file changed +5
-8
lines changed Expand file tree Collapse file tree 1 file changed +5
-8
lines changed Original file line number Diff line number Diff line change @@ -264,17 +264,14 @@ module.exports = {
264
264
} ,
265
265
266
266
// eslint-disable-next-line no-multi-str
267
- 'CallExpression[callee.type="MemberExpression"][callee.property.name=/^push|unshift|splice|with$/],\
268
- CallExpression[callee.type="OptionalMemberExpression"][callee.property.name=/^push|unshift|splice|with$/],\
269
- OptionalCallExpression[callee.type="MemberExpression"][callee.property.name=/^push|unshift|splice|with$/],\
270
- OptionalCallExpression[callee.type="OptionalMemberExpression"][callee.property.name=/^push|unshift|splice|with$/]' ( node ) {
271
- if ( node . arguments . length === 0 ) {
272
- return ;
273
- }
274
-
267
+ 'CallExpression[callee.type="MemberExpression"][callee.property.name=/^push|unshift|splice|with|concat$/],\
268
+ CallExpression[callee.type="OptionalMemberExpression"][callee.property.name=/^push|unshift|splice|with|concat$/],\
269
+ OptionalCallExpression[callee.type="MemberExpression"][callee.property.name=/^push|unshift|splice|with|concat$/],\
270
+ OptionalCallExpression[callee.type="OptionalMemberExpression"][callee.property.name=/^push|unshift|splice|with|concat$/]' ( node ) {
275
271
node . arguments . forEach ( ( arg ) => {
276
272
if ( arg . type === 'JSXElement' && ! hasProp ( arg . openingElement . attributes , 'key' ) ) {
277
273
report ( context , messages . missingIterKey , 'missingArrayKey' , { node } ) ;
274
+ return ;
278
275
}
279
276
if ( arg . type === 'JSXFragment' ) {
280
277
report ( context , messages . missingIterKey , 'missingArrayKeyUsePrag' , { node } ) ;
You can’t perform that action at this time.
0 commit comments