diff --git a/src/dao/AlarmDAO.ts b/src/dao/AlarmDAO.ts index 8466e1f09..2414ab199 100644 --- a/src/dao/AlarmDAO.ts +++ b/src/dao/AlarmDAO.ts @@ -320,7 +320,12 @@ export class AlarmDAO extends AbstractDAO { alarm.uei = data.uei; alarm.description = data.description; alarm.firstEventTime = this.toDate(data.firstEventTime); + + if (!data.lastEvent) { + log.warn(`"lastEvent" missing on alarm id={alarm.id}.`); + } alarm.lastEvent = this.eventDao.fromData(data.lastEvent); + alarm.location = data.location; alarm.logMessage = data.logMessage; alarm.reductionKey = data.reductionKey;