fix(repodb): GQL request for ExpandedRepoInfo errors when artifacts with tags are present (#1265)

If we push an artifact and give it a tag, repodb would crash because of the null pointer dereferencing

Now when iterating over the tags of a repo and stumbling upon a unsupported media type, it's being ignored

Signed-off-by: Laurentiu Niculae <niculae.laurentiu1@gmail.com>
This commit is contained in:
LaurentiuNiculae
2023-03-15 19:34:48 +02:00
committed by GitHub
parent 7656b6f011
commit 150ee88945
7 changed files with 89 additions and 6 deletions
+1 -1
View File
@@ -241,7 +241,7 @@ func TestUploadArtifact(t *testing.T) {
artifact := ispec.Artifact{}
err := test.UploadArtifactManifest(&artifact, baseURL, "test")
err := test.UploadArtifactManifest(&artifact, nil, baseURL, "test")
So(err, ShouldNotBeNil)
})
}