Fix not finding GOG games that use launchers (#149)

This commit is contained in:
Untz64
2022-05-22 19:15:53 +02:00
committed by GitHub
parent 3b4b528b2f
commit 01f051e113
+4 -1
View File
@@ -57,7 +57,10 @@ fn get_shortcuts_from_games(games: Vec<(GogGame, PathBuf)>) -> Vec<GogShortcut>
if let Some(primary_task) = tasks.iter().find(|t| { if let Some(primary_task) = tasks.iter().find(|t| {
t.is_primary.unwrap_or_default() t.is_primary.unwrap_or_default()
&& t.task_type == "FileTask" && t.task_type == "FileTask"
&& t.category.as_ref().unwrap_or(&String::from("")) == "game" && (
t.category.as_ref().unwrap_or(&String::from("")) == "launcher" ||
t.category.as_ref().unwrap_or(&String::from("")) == "game"
)
}) { }) {
if let Some(task_path) = &primary_task.path { if let Some(task_path) = &primary_task.path {
let full_path = game_folder.join(&task_path); let full_path = game_folder.join(&task_path);