Skip to content

Commit 368a3cf

Browse files
author
Jason Rhubottom
committed
Allow for can_dim=false when no type is specified
1 parent e6be03d commit 368a3cf

File tree

2 files changed

+8
-5
lines changed

2 files changed

+8
-5
lines changed

index.js

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1311,10 +1311,13 @@ HomeSeerAccessory.prototype = {
13111311

13121312
this.statusCharacteristic = lightbulbService.getCharacteristic(Characteristic.On);
13131313

1314-
lightbulbService
1315-
.addCharacteristic(new Characteristic.Brightness())
1316-
.on('set', this.setBrightness.bind(this))
1317-
.on('get', this.getValue.bind(this));
1314+
//Allow for dimmable lights
1315+
if (this.config.can_dim == null || this.config.can_dim == true) {
1316+
lightbulbService
1317+
.addCharacteristic(new Characteristic.Brightness())
1318+
.on('set', this.setBrightness.bind(this))
1319+
.on('get', this.getValue.bind(this));
1320+
}
13181321

13191322
services.push(lightbulbService);
13201323
break;

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "homebridge-homeseer-plugin",
3-
"version": "1.0.15",
3+
"version": "1.0.16",
44
"description": "Homeseer Plugin for homebridge: https://github.com/nfarina/homebridge",
55
"license": "ISC",
66
"keywords": [

0 commit comments

Comments
 (0)