Fixed homebridge startup failed when robot does not support zone cleaning

This commit is contained in:
Arne 2019-07-20 22:37:27 +02:00
parent f795781d2a
commit db8305bbee
3 changed files with 14 additions and 2 deletions

View File

@ -83,3 +83,11 @@
## 0.5.2 ## 0.5.2
* Added schema file for use with homebridge-config-ui-x * Added schema file for use with homebridge-config-ui-x
## 0.6.0
* Added support for zone cleaning
## 0.6.1
* Fixed homebridge startup failed when robot does not support zone cleaning

View File

@ -89,6 +89,10 @@ NeatoVacuumRobotPlatform.prototype = {
} }
robot.maps = result; robot.maps = result;
let processedMapCount = 0; let processedMapCount = 0;
if (robot.maps.length === 0)
{
callback();
}
robot.maps.forEach((map) => { robot.maps.forEach((map) => {
robot.getMapBoundaries(map.id, (error, result) => { robot.getMapBoundaries(map.id, (error, result) => {
if (error) { if (error) {

View File

@ -1,6 +1,6 @@
{ {
"name": "homebridge-neato", "name": "homebridge-neato",
"version": "0.6.0", "version": "0.6.1",
"description": "A Neato vacuum robot plugin for homebridge.", "description": "A Neato vacuum robot plugin for homebridge.",
"license": "MIT", "license": "MIT",
"keywords": [ "keywords": [