Fix 410 gone response handling

This commit is contained in:
Eric Huss 2022-10-25 14:45:41 -07:00
parent 8adf1df292
commit c8c6a963c0

View file

@ -235,7 +235,7 @@ impl<'cfg> HttpRegistry<'cfg> {
result.with_context(|| format!("failed to download from `{}`", url))?;
let code = handle.response_code()?;
// Keep this list of expected status codes in sync with the codes handled in `load`
if !matches!(code, 200 | 304 | 401 | 404 | 451) {
if !matches!(code, 200 | 304 | 410 | 404 | 451) {
let url = handle.effective_url()?.unwrap_or(&url);
return Err(HttpNotSuccessful {
code,