fix for EMM-1673

revert-70aa11f8
kamidu 8 years ago
parent 72522ad759
commit 0c70c87406

@ -118,12 +118,17 @@ deviceModule = function () {
if (properties["DEVICE_INFO"]) { if (properties["DEVICE_INFO"]) {
var initialDeviceInfoList = parse(properties["DEVICE_INFO"]); var initialDeviceInfoList = parse(properties["DEVICE_INFO"]);
var initialDeviceInfo = {}; var initialDeviceInfo = {};
if (Array.isArray(initialDeviceInfoList) {
for (var j = 0; j < initialDeviceInfoList.length; j++) { for (var j = 0; j < initialDeviceInfoList.length; j++) {
if (initialDeviceInfoList[j]["value"]) { if (initialDeviceInfoList[j]["value"]) {
initialDeviceInfo[initialDeviceInfoList[j]["name"]] = initialDeviceInfo[initialDeviceInfoList[j]["name"]] =
initialDeviceInfoList[j]["value"]; initialDeviceInfoList[j]["value"];
} }
} }
} else {
initialDeviceInfo = initialDeviceInfoList;
}
filteredDeviceData["initialDeviceInfo"]["DEVICE_INFO"] = initialDeviceInfo; filteredDeviceData["initialDeviceInfo"]["DEVICE_INFO"] = initialDeviceInfo;
} }

Loading…
Cancel
Save