Skip to content

Commit

Permalink
0.8.1
Browse files Browse the repository at this point in the history
  • Loading branch information
cbrandlehner committed Dec 17, 2020
1 parent 1f67b9c commit d4c35df
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 7 deletions.
10 changes: 4 additions & 6 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -28,13 +28,12 @@ class OnkyoPlatform {
platform.log.debug('Creating %s receivers...', platform.numberReceivers);
if (platform.numberReceivers === 0) return;
receivers.forEach(receiver => {
if(!this.connections[receiver.ip_address])
{
platform.log.debug('Creating new connection for ip %s' , receiver.ip_address);
if (!this.connections[receiver.ip_address]) {
platform.log.debug('Creating new connection for ip %s', receiver.ip_address);
this.connections[receiver.ip_address] = require('eiscp');
this.connections[receiver.ip_address].connect({host:receiver.ip_address, reconnect:true,model:receiver.model})

this.connections[receiver.ip_address].connect({host: receiver.ip_address, reconnect: true, model: receiver.model});
}

const accessory = new OnkyoAccessory(platform, receiver);
platform.receiverAccessories.push(accessory);
});
Expand Down Expand Up @@ -150,7 +149,6 @@ class OnkyoAccessory {
this.eiscp.on(this.cmdMap[this.zone].input, this.eventInput.bind(this));

this.setUp();

}

setUp() {
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "homebridge-onkyo",
"version": "0.8.0",
"version": "0.8.1",
"description": "Homebridge plugin for Onkyo Receivers",
"main": "index.js",
"scripts": {
Expand Down

0 comments on commit d4c35df

Please sign in to comment.