File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -109,19 +109,19 @@ function getInlineTypeFix(nodes, sourceCode) {
109109 const nodeClosingBrace = nodeTokens . find ( token => isPunctuator ( token , '}' ) ) ;
110110 // const preferInline = context.options[0] && context.options[0]['prefer-inline'];
111111 if ( nodeClosingBrace ) {
112- for ( const node of rest ) {
112+ rest . forEach ( ( node ) => {
113113 // these will be all Type imports, no Value specifiers
114114 // then add inline type specifiers to importKind === 'type' import
115- for ( const specifier of node . specifiers ) {
115+ node . specifiers . forEach ( ( specifier ) => {
116116 if ( specifier . importKind === 'type' ) {
117117 fixes . push ( fixer . insertTextBefore ( nodeClosingBrace , `, type ${ specifier . local . name } ` ) ) ;
118118 } else {
119119 fixes . push ( fixer . insertTextBefore ( nodeClosingBrace , `, ${ specifier . local . name } ` ) ) ;
120120 }
121- }
121+ } ) ;
122122
123123 fixes . push ( fixer . remove ( node ) ) ;
124- }
124+ } ) ;
125125 } else {
126126 // we have a default import only
127127 const defaultSpecifier = firstImport . specifiers . find ( ( spec ) => spec . type === 'ImportDefaultSpecifier' ) ;
You can’t perform that action at this time.
0 commit comments