mirror of
https://github.com/RetroDECK/ES-DE.git
synced 2024-11-25 23:55:38 +00:00
Fixed crash when TheGamesDB scraper sees a platform it doesn't support.
This commit is contained in:
parent
f7f51c5702
commit
40ca44e54f
|
@ -73,8 +73,14 @@ std::unique_ptr<ScraperSearchHandle> GamesDBScraper::getResultsAsync(const Scrap
|
||||||
|
|
||||||
if(params.system->getPlatformId() != PLATFORM_UNKNOWN)
|
if(params.system->getPlatformId() != PLATFORM_UNKNOWN)
|
||||||
{
|
{
|
||||||
path += "&platform=";
|
auto platformIt = gamesdb_platformid_map.find(params.system->getPlatformId());
|
||||||
path += HttpReq::urlEncode(gamesdb_platformid_map.at(params.system->getPlatformId()));
|
if(platformIt != gamesdb_platformid_map.end())
|
||||||
|
{
|
||||||
|
path += "&platform=";
|
||||||
|
path += HttpReq::urlEncode(platformIt->second);
|
||||||
|
}else{
|
||||||
|
LOG(LogWarning) << "TheGamesDB scraper warning - no support for platform " << getPlatformName(params.system->getPlatformId());
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
path = "thegamesdb.net" + path;
|
path = "thegamesdb.net" + path;
|
||||||
|
|
Loading…
Reference in a new issue