From a0a0206d42911f2c607b0600be8ea2d43fa6df12 Mon Sep 17 00:00:00 2001 From: Brad Date: Wed, 27 Dec 2023 09:51:12 +1100 Subject: [PATCH] Fix for GOG DLC showing up as games. --- src/Data/GOG/GOGLibrary.cs | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/Data/GOG/GOGLibrary.cs b/src/Data/GOG/GOGLibrary.cs index 2b1fc7a..f4db6c5 100644 --- a/src/Data/GOG/GOGLibrary.cs +++ b/src/Data/GOG/GOGLibrary.cs @@ -81,6 +81,13 @@ public async Task> ListGamesAsync() var gameName = gameKey.GetValue("gameName") as String; var gamePath = gameKey.GetValue("path") as String; + // If the entry is DLC we don't need to show it as an individual item. + var dependsOn = gameKey.GetValue("dependsOn") as String; + if (String.IsNullOrEmpty(dependsOn) == false) + { + continue; + } + if (Int32.TryParse(gameId, out int gameIdInt) == true && String.IsNullOrEmpty(gameName) == false && String.IsNullOrEmpty(gamePath) == false) { var game = new GOGGame()