File tree 1 file changed +7
-7
lines changed
app/code/Magento/Catalog/view/adminhtml/web/js
1 file changed +7
-7
lines changed Original file line number Diff line number Diff line change @@ -33,7 +33,6 @@ define([
33
33
data = { } ,
34
34
parameters = { } ,
35
35
root = { } ,
36
- len = 0 ,
37
36
key = '' ;
38
37
39
38
/**
@@ -160,15 +159,15 @@ define([
160
159
* @returns {void }
161
160
*/
162
161
categoryLoader . buildCategoryTree = function ( parent , nodeConfig ) {
163
- var j = 0 ;
162
+ var i = 0 ;
164
163
165
164
if ( ! nodeConfig ) {
166
165
return null ;
167
166
}
168
167
169
168
if ( parent && nodeConfig && nodeConfig . length ) {
170
- for ( j = 0 ; j < nodeConfig . length ; j ++ ) {
171
- categoryLoader . processCategoryTree ( parent , nodeConfig , j ) ;
169
+ for ( i ; i < nodeConfig . length ; i ++ ) {
170
+ categoryLoader . processCategoryTree ( parent , nodeConfig , i ) ;
172
171
}
173
172
}
174
173
} ;
@@ -180,14 +179,15 @@ define([
180
179
* @returns {Object }
181
180
*/
182
181
categoryLoader . buildHashChildren = function ( hash , node ) {
183
- var j = 0 ;
182
+ var i = 0 ,
183
+ len ;
184
184
185
185
if ( node . childNodes . length > 0 || node . loaded === false && node . loading === false ) {
186
186
hash . children = [ ] ;
187
187
188
- for ( j = 0 , len = node . childNodes . length ; j < len ; j ++ ) {
188
+ for ( i , len = node . childNodes . length ; i < len ; i ++ ) {
189
189
hash . children = hash . children ? hash . children : [ ] ;
190
- hash . children . push ( this . buildHash ( node . childNodes [ j ] ) ) ;
190
+ hash . children . push ( this . buildHash ( node . childNodes [ i ] ) ) ;
191
191
}
192
192
}
193
193
You can’t perform that action at this time.
0 commit comments