From 850315ad1c6e70fe276cd7a748457d6f718b5a70 Mon Sep 17 00:00:00 2001 From: Bogdan Date: Wed, 17 Jan 2024 10:44:51 +0200 Subject: [PATCH] Fixed: (GGn) Improve titles and allow only torrents --- .../Indexers/Definitions/GazelleGames.cs | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/src/NzbDrone.Core/Indexers/Definitions/GazelleGames.cs b/src/NzbDrone.Core/Indexers/Definitions/GazelleGames.cs index 115d871e6..da9025a87 100644 --- a/src/NzbDrone.Core/Indexers/Definitions/GazelleGames.cs +++ b/src/NzbDrone.Core/Indexers/Definitions/GazelleGames.cs @@ -394,7 +394,7 @@ namespace NzbDrone.Core.Indexers.Definitions var torrents = groupTorrents .ToObject>(JsonSerializer.Create(Json.GetSerializerSettings())) - .Where(t => t.Value.TorrentType != "Link") + .Where(t => t.Value.TorrentType.ToUpperInvariant() == "TORRENT") .ToList(); var categories = group.Value.Artists @@ -470,6 +470,11 @@ namespace NzbDrone.Core.Indexers.Definitions flags.AddIfNotNull(torrent.Region); flags.AddIfNotNull(torrent.Miscellaneous); + if (torrent.Dupable == 1) + { + flags.Add("Trumpable"); + } + flags = flags.Where(x => x.IsNotNullOrWhiteSpace()).ToList(); if (flags.Any()) @@ -477,6 +482,11 @@ namespace NzbDrone.Core.Indexers.Definitions title += $" [{string.Join(" / ", flags)}]"; } + if (torrent.GameDoxType.IsNotNullOrWhiteSpace()) + { + title += $" [{torrent.GameDoxType.Trim()}]"; + } + return title; } @@ -570,6 +580,7 @@ namespace NzbDrone.Core.Indexers.Definitions public string ReleaseTitle { get; set; } public string Miscellaneous { get; set; } public int Scene { get; set; } + public int Dupable { get; set; } public DateTime Time { get; set; } public string TorrentType { get; set; } public int FileCount { get; set; } @@ -580,6 +591,9 @@ namespace NzbDrone.Core.Indexers.Definitions public GazelleGamesFreeTorrent FreeTorrent { get; set; } public bool PersonalFL { get; set; } public bool LowSeedFL { get; set; } + + [JsonProperty("GameDOXType")] + public string GameDoxType { get; set; } } public class GazelleGamesUserResponse