Fixed bug where real debrid would report torrent links that are empty.

This commit is contained in:
Roger Far 2021-10-21 07:45:18 -06:00
parent 9583eeeeb0
commit 11c65d0017
5 changed files with 13 additions and 7 deletions

View file

@ -4,6 +4,10 @@ All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
## [1.8.8] - 2021-10-21
### Changed
- Fixed starting downloads when RealDebrid reports ghost links in torrents.
## [1.8.7] - 2021-10-11
### Added
- Add Aria2 test connection button.

View file

@ -55,7 +55,7 @@
<a class="navbar-item"> Profile </a>
<a class="navbar-item" (click)="logout()"> Logout </a>
<hr class="navbar-divider" />
<div class="navbar-item">Version 1.8.7</div>
<div class="navbar-item">Version 1.8.8</div>
</div>
</div>
</div>

View file

@ -1,6 +1,6 @@
{
"name": "rdt-client",
"version": "1.8.7",
"version": "1.8.8",
"description": "This is a web interface to manage your torrents on Real-Debrid.",
"main": "index.js",
"dependencies": {

View file

@ -173,15 +173,17 @@ namespace RdtClient.Service.Services
var rdTorrent = await GetRdNetClient().Torrents.GetInfoAsync(torrent.RdId);
var torrentLinks = rdTorrent.Links.Where(m => !String.IsNullOrWhiteSpace(m)).ToList();
// Sometimes RD will give you 1 rar with all files, sometimes it will give you 1 link per file.
if (torrent.Files.Count(m => m.Selected) != rdTorrent.Links.Count &&
torrent.ManualFiles.Count != rdTorrent.Links.Count &&
rdTorrent.Links.Count != 1)
if (torrent.Files.Count(m => m.Selected) != torrentLinks.Count &&
torrent.ManualFiles.Count != torrentLinks.Count &&
torrentLinks.Count != 1)
{
return;
}
foreach (var file in rdTorrent.Links)
foreach (var file in torrentLinks)
{
// Make sure downloads don't get added multiple times
var downloadExists = await _downloads.Get(torrent.TorrentId, file);

View file

@ -4,7 +4,7 @@
<TargetFramework>net5.0</TargetFramework>
<OutputType>Exe</OutputType>
<UserSecretsId>94c24cba-f03f-4453-a671-3640b517c573</UserSecretsId>
<Version>1.8.7</Version>
<Version>1.8.8</Version>
</PropertyGroup>
<ItemGroup>