Skip to content

Commit

Permalink
lint platform.ts
Browse files Browse the repository at this point in the history
  • Loading branch information
Jason-Morcos committed Nov 6, 2023
1 parent 7b2dc7d commit e96880a
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions src/platform.ts
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ export class KumoHomebridgePlatform implements DynamicPlatformPlugin {
}

// loop over the discovered devices and register each one if it has not already been registered
for (let device of this.kumo.devices) {
for (const device of this.kumo.devices) {

// generate a unique id for the accessory this should be generated from
// something globally unique, but constant, for example, the device serial
Expand Down Expand Up @@ -307,9 +307,9 @@ export class KumoHomebridgePlatform implements DynamicPlatformPlugin {

// We've explicitly set an address for this device.
for (const configOption of this.config.options) {
if(configOption.startsWith('Address.' + (device.serial) + '=')) {
return configOption.split('=')[1];
}
if(configOption.startsWith('Address.' + (device.serial) + '=')) {
return configOption.split('=')[1];
}
}

// If we don't have a zoneTable label, we're done here.
Expand All @@ -319,9 +319,9 @@ export class KumoHomebridgePlatform implements DynamicPlatformPlugin {

// We've explicitly set an address for the zoneTable label this device is attached to.
for (const configOption of this.config.options) {
if(configOption.startsWith('Address.' + (device.label) + '=')) {
return configOption.split('=')[1];
}
if(configOption.startsWith('Address.' + (device.label) + '=')) {
return configOption.split('=')[1];
}
}

// Nothing special to do - return default.
Expand Down

0 comments on commit e96880a

Please sign in to comment.