howanghk / homebridge-ewelink

Homebridge plugin to control Sonoff relays with OEM firmware
MIT License
81 stars 46 forks source link

TypeError: accessories.map is not a function #89

Closed neo3 closed 4 years ago

neo3 commented 4 years ago

Hello everyone,

I'm getting the following error when setting Ewelink Max on my Homebridge:

[2020-5-16 10:59:09] [eWeLink] eWeLink HTTPS API reports that there are a total of [0] devices registered [2020-5-16 10:59:09] [eWeLink] As there were no devices were found, all devices have been removed from the platform's cache. Please regiester your devices using the eWeLink app and restart HomeBridge [2020-5-16 10:59:09] TypeError: accessories.map is not a function at Server.handleUnregisterPlatformAccessories (/usr/lib/node_modules/homebridge/src/server.ts:531:40) at HomebridgeAPI.emit (events.js:310:20) at HomebridgeAPI.unregisterPlatformAccessories (/usr/lib/node_modules/homebridge/src/api.ts:311:10) at /usr/lib/node_modules/homebridge-ewelink-max/index.js:125:38 at Object.parseBody (/usr/lib/node_modules/homebridge-ewelink-max/node_modules/request-json/main.js:74:12) at Request._callback (/usr/lib/node_modules/homebridge-ewelink-max/node_modules/request-json/main.js:148:26) at Request.self.callback (/usr/lib/node_modules/homebridge-ewelink-max/node_modules/request/request.js:185:22) at Request.emit (events.js:310:20) at Request. (/usr/lib/node_modules/homebridge-ewelink-max/node_modules/request/request.js:1161:10) at Request.emit (events.js:310:20) [2020-5-16 10:59:09] Got SIGTERM, shutting down Homebridge...