Skip to content

Commit 8d6e277

Browse files
committed
fix: add optional chaining for parameters.install
1 parent 9a5c2fc commit 8d6e277

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

  • src/resources/python/pip

src/resources/python/pip/pip.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -118,7 +118,7 @@ export class Pip extends Resource<PipResourceConfig> {
118118
// The diffing algo is not smart enough to differentiate between same two items but different (modify) and same two items but same (keep).
119119
const parsedInstalledPackages = JSON.parse(installedPackages)
120120
.map(({ name, version }: { name: string; version: string}) => {
121-
const match = parameters.install!.find((p) => {
121+
const match = parameters.install?.find((p) => {
122122
if (typeof p === 'string') {
123123
return p === name;
124124
}

0 commit comments

Comments
 (0)