1
1
mirror of https://github.com/go-gitea/gitea synced 2025-07-15 23:17:19 +00:00

Fix #31185 try fix lfs download from bitbucket failed (#31201)

Fix #31185
This commit is contained in:
Zoupers Zou
2024-06-12 06:22:28 +08:00
committed by GitHub
parent fc2d75f86d
commit e25d6960b5
8 changed files with 16 additions and 13 deletions

View File

@@ -211,7 +211,7 @@ func createRequest(ctx context.Context, method, url string, headers map[string]s
for key, value := range headers {
req.Header.Set(key, value)
}
req.Header.Set("Accept", MediaType)
req.Header.Set("Accept", AcceptHeader)
return req, nil
}
@@ -251,6 +251,6 @@ func handleErrorResponse(resp *http.Response) error {
return err
}
log.Trace("ErrorResponse: %v", er)
log.Trace("ErrorResponse(%v): %v", resp.Status, er)
return errors.New(er.Message)
}