Skip to content

Commit

Permalink
fix the landing accessory data
Browse files Browse the repository at this point in the history
Fix the keywords when to list accessories belong to the subject manifest.

Signed-off-by: wang yan <[email protected]>
  • Loading branch information
wy65701436 authored and YangJiao0817 committed Dec 5, 2023
1 parent 7fee99b commit 7c1a8fd
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/server/middleware/subject/subject.go
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,7 @@ func Middleware() func(http.Handler) http.Handler {
// In certain cases, the OCI client may push the subject artifact and accessory in either order.
// Therefore, it is necessary to handle situations where the client pushes the accessory ahead of the subject artifact.
digest := digest.FromBytes(body)
accs, err := accessory.Mgr.List(ctx, q.New(q.KeyWords{"SubjectArtifactDigest": digest, "SubArtifactRepo": info.Repository}))
accs, err := accessory.Mgr.List(ctx, q.New(q.KeyWords{"SubjectArtifactDigest": digest, "SubjectArtifactRepo": info.Repository}))
if err != nil {
logger.Errorf("failed to list accessory artifact: %s, error: %v", digest, err)
return err
Expand Down

0 comments on commit 7c1a8fd

Please sign in to comment.