Skip to content

Commit

Permalink
review
Browse files Browse the repository at this point in the history
  • Loading branch information
Vandita2020 committed Feb 28, 2024
1 parent c2ae59e commit d99415e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions packages/aws-cdk-lib/aws-lambda-nodejs/lib/bundling.ts
Original file line number Diff line number Diff line change
Expand Up @@ -418,12 +418,12 @@ function toTarget(runtime: Runtime): string {

function toCliArgs(esbuildArgs: { [key: string]: string | boolean }): string {
const args = new Array<string>();
const ls = ['--alias', '--drop', '--pure', '--log-override', '--out-extension'];
const reSpecifiedKeys = ['--alias', '--drop', '--pure', '--log-override', '--out-extension'];

for (const [key, value] of Object.entries(esbuildArgs)) {
if (value === true || value === '') {
args.push(key);
} else if (ls.includes(key)) {
} else if (reSpecifiedKeys.includes(key)) {
args.push(`${key}:"${value}"`);
} else if (value) {
args.push(`${key}="${value}"`);
Expand Down

0 comments on commit d99415e

Please sign in to comment.