Skip to content

Commit c8c6a96

Browse files
committed
Fix 410 gone response handling
1 parent 8adf1df commit c8c6a96

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/cargo/sources/registry/http_remote.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -235,7 +235,7 @@ impl<'cfg> HttpRegistry<'cfg> {
235235
result.with_context(|| format!("failed to download from `{}`", url))?;
236236
let code = handle.response_code()?;
237237
// Keep this list of expected status codes in sync with the codes handled in `load`
238-
if !matches!(code, 200 | 304 | 401 | 404 | 451) {
238+
if !matches!(code, 200 | 304 | 410 | 404 | 451) {
239239
let url = handle.effective_url()?.unwrap_or(&url);
240240
return Err(HttpNotSuccessful {
241241
code,

0 commit comments

Comments
 (0)