Skip to content

Commit

Permalink
Update processEmails.ts
Browse files Browse the repository at this point in the history
  • Loading branch information
jdinh8124 committed Jan 23, 2025
1 parent 8013e1e commit 766b960
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions lib/lambda/processEmails.ts
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,7 @@ export async function processRecord(kafkaRecord: KafkaRecord, config: ProcessEma
const record = JSON.parse(decodeBase64WithUtf8(kafkaRecord.value))
console.log('inside process record', record)
const safeSeatoolRecord = opensearch.main.seatool.transform(record.id).safeParse(record);
console.log('seatool safe record', safeSeatoolRecord)
if(safeSeatoolRecord.data?.cmsStatus === SEATOOL_STATUS.WITHDRAWN) {
//send email
console.log(safeSeatoolRecord.data?.cmsStatus, "seatool status is withdrawn")
Expand Down

0 comments on commit 766b960

Please sign in to comment.