Skip to content
This repository has been archived by the owner on Dec 27, 2019. It is now read-only.

Commit

Permalink
Fix missing MBR device list
Browse files Browse the repository at this point in the history
  • Loading branch information
casperboone committed Sep 2, 2016
1 parent ec28adf commit c95ba38
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 6 deletions.
2 changes: 1 addition & 1 deletion app.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"id": "nl.casperboone.samsungtv",
"version": "0.0.1",
"version": "0.0.2",
"name": {
"en": "Samsung Smart TV"
},
Expand Down
14 changes: 9 additions & 5 deletions samsung-tv-sources.js
Original file line number Diff line number Diff line change
Expand Up @@ -104,12 +104,16 @@ Sources.prototype.update = function () {
} else {

var devices = res['MBRDeviceList']['MBRDevice'];

devices.forEach(function (device) {

object.sources[device.ID[0]].appendToDescription(" - " + device.DeviceType[0] + " - " + device.BrandName[0]);

if (devices) {

devices.forEach(function (device) {

object.sources[device.ID[0]].appendToDescription(" - " + device.DeviceType[0] + " - " + device.BrandName[0]);

});

});
}

}

Expand Down

0 comments on commit c95ba38

Please sign in to comment.