Skip to content

Commit

Permalink
add optional chaining
Browse files Browse the repository at this point in the history
  • Loading branch information
kainpets committed May 15, 2024
1 parent 179ab88 commit 50e31dd
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions lib/interact-for-access-code.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,9 @@ export const interactForAccessCode = async ({
type: "autocomplete",
message: "Select an access_code:",
choices: accessCodes.map((ac: any) => ({
title: ac.properties.name ?? "<No Name>",
value: ac.access_code_id,
description: `${ac.type} ${ac.access_code_id}`,
title: ac?.properties?.name ?? "<No Name>",
value: ac?.access_code_id,
description: `${ac?.type} ${ac?.access_code_id}`,
})),
})

Expand Down

0 comments on commit 50e31dd

Please sign in to comment.