Clear device state when device leaves network. https://github.com/Koenkk/zigbee2mqtt/issues/4485

This commit is contained in:
Koen Kanters
2020-11-02 18:27:06 +01:00
parent 2ee3b5f12b
commit bd7d0be07a
+1
View File
@@ -254,6 +254,7 @@ class Controller {
/* istanbul ignore else */
if (type === 'deviceLeave') {
logger.warn(`Device '${name || data.ieeeAddr}' left the network`);
this.state.remove(data.ieeeAddr);
}
}