diff --git a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/serializers/yarn-queue/capacity-queue.js b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/serializers/yarn-queue/capacity-queue.js index e838255ba1d..57714e3d462 100644 --- a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/serializers/yarn-queue/capacity-queue.js +++ b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/serializers/yarn-queue/capacity-queue.js @@ -24,7 +24,7 @@ export default DS.JSONAPISerializer.extend({ normalizeSingleResponse(store, primaryModelClass, payload, id, requestType) { var children = []; - if (payload.queues) { + if (payload.queues && payload.queues.queue) { payload.queues.queue.forEach(function(queue) { children.push(queue.queueName); }); @@ -122,7 +122,7 @@ export default DS.JSONAPISerializer.extend({ data.push(result.queue); includedData = includedData.concat(result.includedData); - if (payload.queues) { + if (payload.queues && payload.queues.queue) { for (var i = 0; i < payload.queues.queue.length; i++) { var queue = payload.queues.queue[i]; queue.myParent = payload.queueName;