Skip to content

Commit d3f1696

Browse files
committed
refactor(vendir): remove unnecessary nullable check
Similar to fdd1612, the nullable check here doesn't provide any additional value. This also allows us to increase test coverage, because we now don't have code paths that aren't tested.
1 parent fdd1612 commit d3f1696

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

lib/modules/manager/vendir/extract.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -102,13 +102,13 @@ export function extractPackageFile(
102102
// grab the helm charts
103103
const contents = pkg.directories.flatMap((directory) => directory.contents);
104104
for (const content of contents) {
105-
if ('helmChart' in content && content.helmChart) {
105+
if ('helmChart' in content) {
106106
const dep = extractHelmChart(content.helmChart, config.registryAliases);
107107
deps.push(dep);
108-
} else if ('git' in content && content.git) {
108+
} else if ('git' in content) {
109109
const dep = extractGitSource(content.git);
110110
deps.push(dep);
111-
} else if ('githubRelease' in content && content.githubRelease) {
111+
} else if ('githubRelease' in content) {
112112
const dep = extractGithubReleaseSource(content.githubRelease);
113113
deps.push(dep);
114114
}

0 commit comments

Comments
 (0)