Skip to content
This repository has been archived by the owner on Aug 14, 2023. It is now read-only.

Commit

Permalink
fix model for dropcams
Browse files Browse the repository at this point in the history
  • Loading branch information
Brandawg93 committed Jul 20, 2022
1 parent 0bdfe27 commit 8956427
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -290,7 +290,10 @@ class NestCamPlatform implements DynamicPlatformPlugin {
const accessory = new Accessory(displayName, uuid);
accessory.context.cameraInfo = cameraInfo;

const model = cameraInfo.type < ModelTypes.length ? ModelTypes[cameraInfo.type] : 'Nest Camera';
let model = cameraInfo.type < ModelTypes.length ? ModelTypes[cameraInfo.type] : '';
if (!model) {
model = 'Nest Camera';
}
const accessoryInformation = accessory.getService(hap.Service.AccessoryInformation);
if (accessoryInformation) {
accessoryInformation.setCharacteristic(hap.Characteristic.Manufacturer, 'Nest');
Expand Down

0 comments on commit 8956427

Please sign in to comment.