Skip to content

Commit

Permalink
Default to not strictly validating a payload
Browse files Browse the repository at this point in the history
  • Loading branch information
NicholasMTElliott committed Sep 11, 2024
1 parent 855ab0e commit 1b3d8f1
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/lambda.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,8 @@ const logger = winston.createLogger({

let SECRETS = {
GOOGLEAPIKEY: process.env.GOOGLEAPIKEY,
STORAGE_BUCKET: process.env.STORAGE_BUCKET
STORAGE_BUCKET: process.env.STORAGE_BUCKET,
VALIDATE_API_PAYLOADS: undefined
}


Expand Down Expand Up @@ -91,7 +92,7 @@ export const handler: Handler = async (event: APIGatewayProxyEventV2, context):
// Create the controller that'll actually process the request.
const server = new PdfController(logger, {
GoogleApiKey: SECRETS.GOOGLEAPIKEY ?? 'UNKNOWN',
ValidateApiPayloads: true
ValidateApiPayloads: SECRETS.VALIDATE_API_PAYLOADS
});

const result = await server.process(event.body!);
Expand Down

0 comments on commit 1b3d8f1

Please sign in to comment.