mirror of
https://github.com/Radarr/Radarr
synced 2026-05-09 06:13:24 +02:00
Treat HTTP 410 response for failed download similarly to HTTP 404
(cherry picked from commit 818ae02a7a8f0a8ea0a44e0015e2667d96453332)
This commit is contained in:
parent
ac2d92007e
commit
a10759c7e9
2 changed files with 2 additions and 2 deletions
|
|
@ -172,7 +172,7 @@ private async Task<string> DownloadFromWebUrl(RemoteMovie remoteMovie, IIndexer
|
|||
}
|
||||
catch (HttpException ex)
|
||||
{
|
||||
if (ex.Response.StatusCode == HttpStatusCode.NotFound)
|
||||
if (ex.Response.StatusCode is HttpStatusCode.NotFound or HttpStatusCode.Gone)
|
||||
{
|
||||
_logger.Error(ex, "Downloading torrent file for movie '{0}' failed since it no longer exists ({1})", remoteMovie.Release.Title, torrentUrl);
|
||||
throw new ReleaseUnavailableException(remoteMovie.Release, "Downloading torrent failed", ex);
|
||||
|
|
|
|||
|
|
@ -59,7 +59,7 @@ public override async Task<string> Download(RemoteMovie remoteMovie, IIndexer in
|
|||
}
|
||||
catch (HttpException ex)
|
||||
{
|
||||
if (ex.Response.StatusCode == HttpStatusCode.NotFound)
|
||||
if (ex.Response.StatusCode is HttpStatusCode.NotFound or HttpStatusCode.Gone)
|
||||
{
|
||||
_logger.Error(ex, "Downloading nzb file for movie '{0}' failed since it no longer exists ({1})", remoteMovie.Release.Title, url);
|
||||
throw new ReleaseUnavailableException(remoteMovie.Release, "Downloading nzb failed", ex);
|
||||
|
|
|
|||
Loading…
Reference in a new issue