Skip to content

Commit

Permalink
Add dateCode to getDeviceInfoForMqtt. Koenkk#1213
Browse files Browse the repository at this point in the history
  • Loading branch information
Koenkk committed Mar 28, 2019
1 parent 8ee2941 commit bc67755
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion lib/controller.js
Original file line number Diff line number Diff line change
Expand Up @@ -268,7 +268,9 @@ class Controller {

getDeviceInfoForMqtt(ieeeAddr) {
const device = this.zigbee.getDevice(ieeeAddr);
const {type, nwkAddr, manufId, manufName, powerSource, modelId, hwVersion, swBuildId, status} = device;
const {
type, nwkAddr, manufId, manufName, powerSource, modelId, hwVersion, swBuildId, status, dateCode,
} = device;
const deviceSettings = settings.getDevice(device.ieeeAddr);

return {
Expand All @@ -282,6 +284,7 @@ class Controller {
modelId,
hwVersion: hwVersion ? hwVersion : 'unknown',
swBuildId: swBuildId ? swBuildId : 'unknown',
dateCode: dateCode ? dateCode : 'unknown',
status,
};
}
Expand Down

0 comments on commit bc67755

Please sign in to comment.