Fixed 'Refine Search' for the TheGamesDB scraper which I apparently broke in the last commit.

This commit is contained in:
Leon Styhre 2020-06-25 20:37:41 +02:00
parent 0387d515fb
commit ee4a55e9d6

View file

@ -129,19 +129,17 @@ void thegamesdb_generate_json_scraper_requests(
if (params.system->hasPlatformId(PlatformIds::ARCADE) || if (params.system->hasPlatformId(PlatformIds::ARCADE) ||
params.system->hasPlatformId(PlatformIds::NEOGEO)) { params.system->hasPlatformId(PlatformIds::NEOGEO)) {
cleanName = params.game->getName(); cleanName = params.game->getName();
cleanName = MameNames::getInstance()->getCleanName(params.game->getCleanName()); cleanName = MameNames::getInstance()->getCleanName(params.game->getCleanName());
} }
else { else {
cleanName = params.game->getCleanName(); cleanName = params.game->getCleanName();
} }
}
path += "/Games/ByGameName?" + apiKey + path += "/Games/ByGameName?" + apiKey +
"&fields=players,publishers,genres,overview,last_updated,rating," "&fields=players,publishers,genres,overview,last_updated,rating,"
"platform,coop,youtube,os,processor,ram,hdd,video,sound,alternates&name=" + "platform,coop,youtube,os,processor,ram,hdd,video,sound,alternates&name=" +
HttpReq::urlEncode(cleanName); HttpReq::urlEncode(cleanName);
} }
}
if (usingGameID) { if (usingGameID) {
// If we have the ID already, we don't need the GetGameList request. // If we have the ID already, we don't need the GetGameList request.