Unverified Commit 6fc9d227 authored by Tobias Heinze's avatar Tobias Heinze Committed by GitHub
Browse files

server: fix blob download when receiving a 200 response (#6656)

parent f27c00d8
...@@ -256,7 +256,7 @@ func (b *blobDownload) run(ctx context.Context, requestURL *url.URL, opts *regis ...@@ -256,7 +256,7 @@ func (b *blobDownload) run(ctx context.Context, requestURL *url.URL, opts *regis
continue continue
} }
defer resp.Body.Close() defer resp.Body.Close()
if resp.StatusCode != http.StatusTemporaryRedirect { if resp.StatusCode != http.StatusTemporaryRedirect && resp.StatusCode != http.StatusOK {
return nil, fmt.Errorf("unexpected status code %d", resp.StatusCode) return nil, fmt.Errorf("unexpected status code %d", resp.StatusCode)
} }
return resp.Location() return resp.Location()
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment