Skip to content

Commit

Permalink
Rename white noise accessory
Browse files Browse the repository at this point in the history
  • Loading branch information
ollief87 committed Dec 11, 2024
1 parent 984dbf1 commit 86e5215
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
8 changes: 4 additions & 4 deletions src/accessory/AccessoryFactory.ts
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ import VibrationSensorAccessory from './VibrationSensorAccessory';
import WeatherStationAccessory from './WeatherStationAccessory';
import DoorbellAccessory from './DoorbellAccessory';
import PetFeederAccessory from './PetFeederAccessory';
import WhiteNoiseMachineAccessory from './WhiteNoiseMachineAccessory';
import WhiteNoiseLightAccessory from './WhiteNoiseLightAccessory';


export default class AccessoryFactory {
Expand Down Expand Up @@ -92,6 +92,9 @@ export default class AccessoryFactory {
case 'cjkg':
handler = new SceneSwitchAccessory(platform, accessory);
break;
case 'bzyd':
handler = new WhiteNoiseLightAccessory(platform, accessory);
break;

// Large Home Appliances
case 'kt':
Expand Down Expand Up @@ -144,9 +147,6 @@ export default class AccessoryFactory {
case 'yyj':
handler = new ExtractionHoodAccessory(platform, accessory);
break;
case 'bzyd':
handler = new WhiteNoiseMachineAccessory(platform, accessory);
break;

// Security & Video Surveillance
case 'sp':
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,13 @@ const SCHEMA_CODE = {
LIGHT_COLOR: ["colour_data"],
};

export default class WhiteNoiseMachineAccessory extends BaseAccessory {
export default class WhiteNoiseLightAccessory extends BaseAccessory {
requiredSchema() {
return [SCHEMA_CODE.MUSIC_ON, SCHEMA_CODE.LIGHT_ON];
}

configureServices() {
// Music / White Noise
// White Noise
configureOn(this, undefined, this.getSchema(...SCHEMA_CODE.MUSIC_ON));

// Light
Expand Down

0 comments on commit 86e5215

Please sign in to comment.