fix: secret reference skip if not found

This commit is contained in:
=
2024-09-10 22:23:40 +05:30
parent ea3b3c5cec
commit ed71e651f6

View File

@@ -444,7 +444,9 @@ export const expandSecretReferencesFactory = ({
depth: depth + 1
});
}
expandedValue = expandedValue.replaceAll(interpolationSyntax, referedValue);
if (referedValue) {
expandedValue = expandedValue.replaceAll(interpolationSyntax, referedValue);
}
} else {
const secretReferenceEnvironment = entities[0];
const secretReferencePath = path.join("/", ...entities.slice(1, entities.length - 1));
@@ -463,7 +465,9 @@ export const expandSecretReferencesFactory = ({
});
}
expandedValue = expandedValue.replaceAll(interpolationSyntax, referedValue);
if (referedValue) {
expandedValue = expandedValue.replaceAll(interpolationSyntax, referedValue);
}
}
}
}