diff --git a/src/index.ts b/src/index.ts index 1ea3018..8cbed2b 100644 --- a/src/index.ts +++ b/src/index.ts @@ -204,10 +204,13 @@ class AEGWellbeingPlatform implements DynamicPlatformPlugin { const state = this.getApplianceState(pncId, data); // Guard against missing data due to API request failure. - if (!state) { + if (!state || !state.name) { + this.log.warn(`No appliance data returned by API for ${pncId}`); return; } + // this.log.debug(JSON.stringify(state)); + // Keep firmware revision up-to-date in case the device is updated. accessory .getService(Service.AccessoryInformation)!