Skip to content

Commit

Permalink
Merge pull request #16 from martijnvdp/fix-check-digest
Browse files Browse the repository at this point in the history
fix check digest for v1 manifest skip digest check
  • Loading branch information
martijnvdp authored Mar 15, 2023
2 parents 3eee620 + c31eadb commit 6b7bfbf
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion pkg/lambda/check_digest.go
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ func checkDigest(imageName string, resultPublicRepoTags *[]string, resultsFromEc
if err != nil {
return result, err
}
match := (*resultsFromEcr)[imageName+":"+tag].hash == digest
match := (*resultsFromEcr)[imageName+":"+tag].hash == digest || digest == ""

if !match {
result = append(result, tag)
Expand Down
4 changes: 2 additions & 2 deletions pkg/lambda/check_digest_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -91,8 +91,8 @@ func Test_checkDigest(t *testing.T) {
},
},
},
name: "checkV1ImageContinueOnErrAndAddToResult",
wantResult: []string{"v1.4.2"},
name: "checkV1ImageContinueOnErr",
wantResult: nil,
wantErr: false,
},
}
Expand Down

0 comments on commit 6b7bfbf

Please sign in to comment.