@@ -96,9 +96,9 @@ module.exports._getDependencies = function(config = {}) {
9696
9797 const resolvedDependencies = [ ] ;
9898
99- for ( const dep of dependencies ) {
99+ for ( const dependency of dependencies ) {
100100 const result = cabinet ( {
101- partial : dep ,
101+ partial : dependency ,
102102 filename : config . filename ,
103103 directory : config . directory ,
104104 ast : precinct . ast ,
@@ -111,16 +111,16 @@ module.exports._getDependencies = function(config = {}) {
111111 } ) ;
112112
113113 if ( ! result ) {
114- debug ( `skipping an empty filepath resolution for partial: ${ dep } ` ) ;
115- config . nonExistent . push ( dep ) ;
114+ debug ( `skipping an empty filepath resolution for partial: ${ dependency } ` ) ;
115+ config . nonExistent . push ( dependency ) ;
116116 continue ;
117117 }
118118
119119 const exists = fs . existsSync ( result ) ;
120120
121121 if ( ! exists ) {
122- config . nonExistent . push ( dep ) ;
123- debug ( `skipping non-empty but non-existent resolution: ${ result } for partial: ${ dep } ` ) ;
122+ config . nonExistent . push ( dependency ) ;
123+ debug ( `skipping non-empty but non-existent resolution: ${ result } for partial: ${ dependency } ` ) ;
124124 continue ;
125125 }
126126
@@ -159,16 +159,16 @@ function traverse(config = {}) {
159159 debug ( `filtered number of dependencies: ${ dependencies . length } ` ) ;
160160 }
161161
162- for ( const dep of dependencies ) {
162+ for ( const dependency of dependencies ) {
163163 const localConfig = config . clone ( ) ;
164- localConfig . filename = dep ;
164+ localConfig . filename = dependency ;
165165
166166 if ( localConfig . isListForm ) {
167167 for ( const item of traverse ( localConfig ) ) {
168168 subTree . add ( item ) ;
169169 }
170170 } else {
171- subTree [ dep ] = traverse ( localConfig ) ;
171+ subTree [ dependency ] = traverse ( localConfig ) ;
172172 }
173173 }
174174
@@ -187,7 +187,9 @@ function dedupeNonExistent(nonExistent) {
187187 const deduped = new Set ( nonExistent ) ;
188188 nonExistent . length = deduped . size ;
189189
190- for ( const { elem, i } of Object . entries ( deduped ) ) {
190+ let i = 0 ;
191+ for ( const elem of deduped ) {
191192 nonExistent [ i ] = elem ;
193+ i ++ ;
192194 }
193195}
0 commit comments