Skip to content

Commit 5b19d3c

Browse files
committed
Merge remote-tracking branch 'origin/MAGETWO-99361' into 2.3-develop-pr25
2 parents 41b60a4 + 5564158 commit 5b19d3c

File tree

1 file changed

+17
-2
lines changed

1 file changed

+17
-2
lines changed

app/code/Magento/Catalog/view/adminhtml/web/js/category-tree.js

Lines changed: 17 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,8 +37,8 @@ define([
3737
ajax: {
3838
url: options.url,
3939
type: 'POST',
40-
success: $.proxy(function (node) {
41-
return this._convertData(node[0]);
40+
success: $.proxy(function (nodes) {
41+
return this._convertDataNodes(nodes);
4242
}, this),
4343

4444
/**
@@ -77,6 +77,21 @@ define([
7777
}
7878
},
7979

80+
/**
81+
* @param {Array} nodes
82+
* @returns {Array}
83+
* @private
84+
*/
85+
_convertDataNodes: function (nodes) {
86+
var nodesData = [];
87+
88+
nodes.forEach(function (node) {
89+
nodesData.push(this._convertData(node));
90+
}, this);
91+
92+
return nodesData;
93+
},
94+
8095
/**
8196
* @param {Object} node
8297
* @return {*}

0 commit comments

Comments
 (0)