Description is an empty string if not set

This commit is contained in:
Nemirtingas 2019-09-01 22:19:36 +02:00
parent 86b178f55b
commit cfa04f2df8
1 changed files with 4 additions and 1 deletions

View File

@ -254,7 +254,10 @@ void generate_achievements(CurlEasy &easy)
output_json[i]["hidden"] = std::to_string(item.value()["hidden"].get<int>());
try
{
output_json[i]["description"] = item.value()["description"];
if( !item.value()["description"].is_null() )
output_json[i]["description"] = item.value()["description"];
else
output_json[i]["description"] = "";
}
catch (...)
{