Skip to content

Commit

Permalink
withdraw chip rai - added the cms reciepents to datalist & added cogn…
Browse files Browse the repository at this point in the history
…ito to lookup list to fix issue where no email isnt being sent
  • Loading branch information
andieswift committed Aug 16, 2024
1 parent 4bcd8b0 commit 7447590
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 5 deletions.
6 changes: 4 additions & 2 deletions lib/libs/email/bundle-lib.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { Action } from "shared-types";
import { Action } from "../../packages/shared-types";
import { DecodedRecord } from "./handler-lib";

interface EmailCommand {
Expand Down Expand Up @@ -258,7 +258,7 @@ const getBundleFromEvent = (
};
case "respond-to-rai-chip-spa":
return {
lookupList: ["osInsights"],
lookupList: ["osInsights", "cognito"],
dataList: [
"osgEmail",
"chipInbox",
Expand All @@ -274,6 +274,8 @@ const getBundleFromEvent = (
"additionalInformation",
"formattedFileList",
"textFileList",
"srt",
"cpoc",
],
emailCommands: [
{
Expand Down
7 changes: 4 additions & 3 deletions lib/libs/email/data-lib.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ import {
AttachmentKey,
attachmentTitleMap,
EmailAddresses,
} from "shared-types";
import { getSecret } from "shared-utils";
} from "../../packages/shared-types";
import { getSecret } from "../../packages/shared-utils";

interface Attachment {
title: keyof typeof attachmentTitleMap;
Expand Down Expand Up @@ -172,7 +172,8 @@ export const buildEmailData = async (
`'${dataType} Substitute' <[email protected]>`;
break;
case "additionalInformation":
returnObject[dataType] = data[dataType] ?? "No additional information submitted";
returnObject[dataType] =
data[dataType] ?? "No additional information submitted";
break;
default:
returnObject[dataType] =
Expand Down
2 changes: 2 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@
"cdk-serverless-clamscan": "^2.8.1",
"constructs": "^10.3.0",
"esbuild": "^0.21.5",
"luxon": "^3.5.0",
"source-map-support": "^0.5.21",
"tsx": "4.15.7"
},
Expand All @@ -49,6 +50,7 @@
"@semantic-release/changelog": "^6.0.3",
"@semantic-release/git": "^10.0.1",
"@types/jest": "^29.5.12",
"@types/luxon": "^3.4.2",
"@types/node": "20.14.2",
"@vitest/coverage-c8": "^0.29.8",
"@vitest/coverage-istanbul": "^2.0.5",
Expand Down

0 comments on commit 7447590

Please sign in to comment.