[bB] Prevent double slash in links (#9762)

* Prevent double slash in links
It was being added twice to the details and download URLs. despite still being a valid URI, sonarr freaks out and cannot deal with it and throws away any such links.
* redact name as per site rules
This commit is contained in:
mueslo
2020-10-06 19:46:13 +02:00
committed by GitHub
parent 3f74b20ee0
commit f97a0876a2
2 changed files with 4 additions and 4 deletions

View File

@@ -248,7 +248,7 @@ Developer note: The software implements the [Torznab](https://github.com/Sonarr/
* BTNext (BTNT) * BTNext (BTNT)
* BTSCHOOL * BTSCHOOL
* Back-ups * Back-ups
* BaconBits (bB) * bB
* BakaBT * BakaBT
* BeiTai * BeiTai
* BeyondHD (BHD) * BeyondHD (BHD)

View File

@@ -36,7 +36,7 @@ namespace Jackett.Common.Indexers
public BB(IIndexerConfigurationService configService, WebClient w, Logger l, IProtectionService ps) public BB(IIndexerConfigurationService configService, WebClient w, Logger l, IProtectionService ps)
: base(id: "bb", : base(id: "bb",
name: "bB", name: "bB",
description: "BaconBits (bB) is a Private Torrent Tracker for 0DAY / GENERAL", description: "bB is a Private Torrent Tracker for 0DAY / GENERAL",
link: StringUtil.FromBase64("aHR0cHM6Ly9iYWNvbmJpdHMub3JnLw=="), link: StringUtil.FromBase64("aHR0cHM6Ly9iYWNvbmJpdHMub3JnLw=="),
caps: new TorznabCapabilities(), caps: new TorznabCapabilities(),
configService: configService, configService: configService,
@@ -157,11 +157,11 @@ namespace Jackett.Common.Indexers
release.Category = MapTrackerCatToNewznab(catStr); release.Category = MapTrackerCatToNewznab(catStr);
var qDetails = row.Children[1].QuerySelector("a[title='View Torrent']"); var qDetails = row.Children[1].QuerySelector("a[title='View Torrent']");
release.Comments = new Uri(BaseUrl + "/" + qDetails.GetAttribute("href")); release.Comments = new Uri(BaseUri + qDetails.GetAttribute("href"));
release.Guid = release.Comments; release.Guid = release.Comments;
var qDownload = row.Children[1].QuerySelector("a[title='Download']"); var qDownload = row.Children[1].QuerySelector("a[title='Download']");
release.Link = new Uri(BaseUrl + "/" + qDownload.GetAttribute("href")); release.Link = new Uri(BaseUri + qDownload.GetAttribute("href"));
var dateStr = row.Children[3].TextContent.Trim().Replace(" and", ""); var dateStr = row.Children[3].TextContent.Trim().Replace(" and", "");
release.PublishDate = DateTimeUtil.FromTimeAgo(dateStr); release.PublishDate = DateTimeUtil.FromTimeAgo(dateStr);