Skip to content

Commit

Permalink
Merge pull request #91 from B-a-S/master
Browse files Browse the repository at this point in the history
Solving interpolation issue in case an empty key
  • Loading branch information
artemry-nv committed Jul 10, 2024
2 parents 03f48de + 007076c commit abc0a9c
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/com/mellanox/cicd/Matrix.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -868,12 +868,12 @@ def replaceVars(vars, str) {

for (def entry in entrySet(vars)) {

if (entry.key == "" || entry.key == null || entry.value == "" || entry.value == null) {
continue;
}
if (!res.contains('$')) {
return res
}
if (entry.value == null) {
continue;
}
def opts = ['$' + entry.key, '${' + entry.key + '}']
for (int i=0; i<opts.size(); i++) {
if (res.contains(opts[i])) {
Expand Down

0 comments on commit abc0a9c

Please sign in to comment.