Skip to content

Commit

Permalink
Update HueSensor.js
Browse files Browse the repository at this point in the history
Support new model Heiman siren, see #614
  • Loading branch information
ebaauw committed Feb 7, 2020
1 parent 5d5697e commit fede2d6
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions lib/HueSensor.js
Original file line number Diff line number Diff line change
Expand Up @@ -980,8 +980,8 @@ function HueSensor (accessory, id, obj) {
break
case 'ZHAAlarm':
if (
this.obj.manufacturername === 'Heiman' &&
this.obj.modelid === 'WarningDevice'
this.obj.manufacturername.toLowercase() === 'heiman' &&
this.obj.modelid.startsWith('WarningDevice')
) {
// Heiman Siren
} else {
Expand Down Expand Up @@ -1028,11 +1028,11 @@ function HueSensor (accessory, id, obj) {
break
case 'ZHAFire':
if (
(this.obj.manufacturername === 'Heiman' ||
this.obj.manufacturername === 'HEIMAN') &&
(this.obj.modelid === 'SMOK_V16' ||
this.obj.modelid === 'GAS_V15' ||
this.obj.modelid === 'SmokeSensor-N-3.0')
this.obj.manufacturername.toLowercase() === 'heiman' && (
this.obj.modelid === 'SMOK_V16' ||
this.obj.modelid === 'GAS_V15' ||
this.obj.modelid === 'SmokeSensor-N-3.0'
)
) {
// Heiman fire sensor
// Heiman gas sensor
Expand Down

0 comments on commit fede2d6

Please sign in to comment.