Skip to content

Commit

Permalink
Don't use eventstream when forceHttp has been set.
Browse files Browse the repository at this point in the history
See #1196.
  • Loading branch information
ebaauw committed Nov 11, 2024
1 parent 512c5a6 commit c9824e9
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion config.schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@
}
},
"forceHttp": {
"description": "Use plain http instead of https.",
"description": "Use plain HTTP instead of HTTPS. Default: false.<br>Note that this will also disable the use of the Hue bridge event stream.",
"type": "boolean"
},
"groups": {
Expand Down
2 changes: 1 addition & 1 deletion lib/HueBridge.js
Original file line number Diff line number Diff line change
Expand Up @@ -584,7 +584,7 @@ class HueBridge {
this.state.rules = Object.keys(this.rules).length
this.log.debug('%s: %d rules', this.name, this.state.rules)
this.log.debug('%s: %d groups', this.name, this.state.groups)
if (this.hueClient.isHue2) {
if (this.hueClient.isHue2 && !this.platform.config.forceHttp) {
await this.listen()
}
}
Expand Down
2 changes: 1 addition & 1 deletion lib/HueSensor.js
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ class HueSensor {
this.hk = {}
this.resource = '/sensors/' + id
this.serviceList = []
this.noEventStream = !this.bridge.hueClient.isHue2
this.noEventStream = this.bridge.eventStream == null

if (this.obj.type[0] === 'Z') {
// Zigbee sensor.
Expand Down

0 comments on commit c9824e9

Please sign in to comment.