Skip to content

Commit

Permalink
add check
Browse files Browse the repository at this point in the history
  • Loading branch information
Feilner committed Sep 29, 2022
1 parent cacc892 commit f2d0069
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion index.js
Original file line number Diff line number Diff line change
Expand Up @@ -1448,7 +1448,7 @@ function GenericPLCAccessory(platform, config, accessoryNumber) {
this.modTargetGet = function(value){return this.mapFunction(value, config.mapTargetAirPurifierStateSet);}.bind(this);
}

if ('get_TargetAirPurifierState' in config) {
if ('get_TargetAirPurifierState' in config && 'set_TargetAirPurifierState' in config ) {
this.service.getCharacteristic(Characteristic.TargetAirPurifierState)
.on('get', function(callback) {this.getByte(callback,
config.db,
Expand Down

0 comments on commit f2d0069

Please sign in to comment.