Fixed rare issue where the download link would be empty or invalid.
This commit is contained in:
parent
94804d7cba
commit
fa9c839be0
1 changed files with 10 additions and 2 deletions
|
|
@ -237,8 +237,16 @@ namespace RdtClient.Service.Services
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
var downloadLink = await _torrents.UnrestrictLink(download.DownloadId);
|
try
|
||||||
download.Link = downloadLink;
|
{
|
||||||
|
var downloadLink = await _torrents.UnrestrictLink(download.DownloadId);
|
||||||
|
download.Link = downloadLink;
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
await _downloads.UpdateError(download.DownloadId, ex.Message);
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
download.DownloadStarted = DateTime.UtcNow;
|
download.DownloadStarted = DateTime.UtcNow;
|
||||||
await _downloads.UpdateDownloadStarted(download.DownloadId, download.DownloadStarted);
|
await _downloads.UpdateDownloadStarted(download.DownloadId, download.DownloadStarted);
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue