oneday-core
Advanced tools
Comparing version 1.0.47 to 1.0.48
10
index.js
@@ -148,3 +148,3 @@ 'use strict'; | ||
}; | ||
const currentEventLog = await core.getFromDb(params); | ||
const currentEventLog = await db.getFromDb(params); | ||
if (currentEventLog.length > 0 && currentEventLog[0].responseCode === 200) { | ||
@@ -167,3 +167,3 @@ console.log('Event has already been successfully processed. NotificationId: ' + notificationId + ', Original RequestId: ' + originalRequestId); | ||
}; | ||
await core.create(params); | ||
await db.create(params); | ||
console.log('Processing event. NotificationId: ' + notificationId + ', Original RequestId: ' + originalRequestId); | ||
@@ -175,7 +175,7 @@ } | ||
if (core.get(notification.body) === null) { | ||
if (util.get(notification.body) === null) { | ||
await updateNotificationLog(200, 'Null record body. Skipped processing.'); | ||
} | ||
if (core.get(notification.messageAttributes.EntityType.stringValue) === null || | ||
core.get(notification.messageAttributes.EventType.stringValue) === null) { | ||
if (util.get(notification.messageAttributes.EntityType.stringValue) === null || | ||
util.get(notification.messageAttributes.EventType.stringValue) === null) { | ||
await updateNotificationLog(500, 'Missing mandatory params. Unable to process event.'); | ||
@@ -182,0 +182,0 @@ } |
{ | ||
"name": "oneday-core", | ||
"version": "1.0.47", | ||
"version": "1.0.48", | ||
"description": "Basic AWS util functions to ease development.", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
30884