mirror of
https://github.com/Koenkk/zigbee2mqtt.git
synced 2024-11-16 18:39:09 -07:00
Postfix all properties with endpoint name. https://github.com/Koenkk/zigbee-herdsman-converters/pull/2735
This commit is contained in:
parent
234e39eaea
commit
1985e24517
@ -235,13 +235,11 @@ class EntityPublish extends Extension {
|
||||
const msg = result.state;
|
||||
|
||||
if (endpointName) {
|
||||
for (const key of ['state', 'brightness', 'color', 'color_temp', 'color_mode']) {
|
||||
if (msg.hasOwnProperty(key)) {
|
||||
for (const key of Object.keys(msg)) {
|
||||
msg[`${key}_${endpointName}`] = msg[key];
|
||||
delete msg[key];
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// filter out attribute listed in filtered_optimistic
|
||||
if (options.hasOwnProperty('filtered_optimistic')) {
|
||||
|
Loading…
Reference in New Issue
Block a user