Merge pull request #715 from Cucumberrbob/fix/use-getsymlinkpath-method
Actually use `GetSymlinkPath` logic
This commit is contained in:
commit
7436e2d036
2 changed files with 3 additions and 3 deletions
|
|
@ -33,6 +33,8 @@ public class DownloadClient(Download download, Torrent torrent, String destinati
|
||||||
|
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
|
Type = torrent.DownloadClient;
|
||||||
|
|
||||||
if (download.Link == null)
|
if (download.Link == null)
|
||||||
{
|
{
|
||||||
throw new($"Invalid download link");
|
throw new($"Invalid download link");
|
||||||
|
|
@ -56,8 +58,6 @@ public class DownloadClient(Download download, Torrent torrent, String destinati
|
||||||
throw new("Invalid download path");
|
throw new("Invalid download path");
|
||||||
}
|
}
|
||||||
|
|
||||||
Type = torrent.DownloadClient;
|
|
||||||
|
|
||||||
if (Type != Data.Enums.DownloadClient.Symlink)
|
if (Type != Data.Enums.DownloadClient.Symlink)
|
||||||
{
|
{
|
||||||
await FileHelper.Delete(filePath);
|
await FileHelper.Delete(filePath);
|
||||||
|
|
|
||||||
|
|
@ -199,7 +199,7 @@ public class AllDebridTorrentClient(ILogger<AllDebridTorrentClient> logger, IAll
|
||||||
torrent.RdSize = torrentClientTorrent.Bytes;
|
torrent.RdSize = torrentClientTorrent.Bytes;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (torrentClientTorrent.Files != null)
|
if (torrentClientTorrent.Files != null && torrentClientTorrent.Files.Any())
|
||||||
{
|
{
|
||||||
torrent.RdFiles = JsonConvert.SerializeObject(torrentClientTorrent.Files);
|
torrent.RdFiles = JsonConvert.SerializeObject(torrentClientTorrent.Files);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue