Switch true/false conditionals to boolean

This commit is contained in:
tsightler
2023-08-28 21:39:42 -04:00
parent 7e2ab22797
commit 19e3dcc1a3
16 changed files with 44 additions and 44 deletions

View File

@@ -82,7 +82,7 @@ export default class BinarySensor extends RingSocketDevice {
}
publishState(data) {
const isPublish = data === undefined ? true : false
const isPublish = Boolean(data === undefined)
const contactState = this.device.data.faulted ? 'ON' : 'OFF'
this.mqttPublish(this.entity[this.entityName].state_topic, contactState)
this.publishBypassModeState(isPublish)