remotes: FetchByDigest: propagate media type from config to desc
A media type string passed via `WithMediaType()` was not propagated to a descriptor returned by `FetchByDigest()`. Follow-up to PR 8744 Signed-off-by: Akihiro Suda <akihiro.suda.cz@hco.ntt.co.jp>
This commit is contained in:
		| @@ -491,10 +491,11 @@ var ( | ||||
| 				if err != nil { | ||||
| 					return err | ||||
| 				} | ||||
| 				rc, _, err := fetcherByDigest.FetchByDigest(ctx, dgst, remotes.WithMediaType(context.String("media-type"))) | ||||
| 				rc, desc, err := fetcherByDigest.FetchByDigest(ctx, dgst, remotes.WithMediaType(context.String("media-type"))) | ||||
| 				if err != nil { | ||||
| 					return err | ||||
| 				} | ||||
| 				log.G(ctx).Debugf("desc=%+v", desc) | ||||
| 				_, err = io.Copy(os.Stdout, rc) | ||||
| 				rc.Close() | ||||
| 				if err != nil { | ||||
|   | ||||
		Reference in New Issue
	
	Block a user
	 Akihiro Suda
					Akihiro Suda