Merge pull request #1257 from aaronlehmann/remove-extra-stat

Remove unnecessary stat from blob Get method
This commit is contained in:
Stephen Day 2015-12-17 14:10:12 -08:00
commit f72093134f

View file

@ -377,11 +377,7 @@ func (bs *blobs) Stat(ctx context.Context, dgst digest.Digest) (distribution.Des
}
func (bs *blobs) Get(ctx context.Context, dgst digest.Digest) ([]byte, error) {
desc, err := bs.Stat(ctx, dgst)
if err != nil {
return nil, err
}
reader, err := bs.Open(ctx, desc.Digest)
reader, err := bs.Open(ctx, dgst)
if err != nil {
return nil, err
}