Fix compilation of configuration.cpp in Ubuntu 22.04
This commit is contained in:
@@ -20,6 +20,9 @@
|
|||||||
#include <filesystem>
|
#include <filesystem>
|
||||||
#include <fstream>
|
#include <fstream>
|
||||||
#define JSON_DISABLE_ENUM_SERIALIZATION 1
|
#define JSON_DISABLE_ENUM_SERIALIZATION 1
|
||||||
|
#ifdef JSON_DIAGNOSTICS
|
||||||
|
#undef JSON_DIAGNOSTICS
|
||||||
|
#endif
|
||||||
#define JSON_DIAGNOSTICS 1
|
#define JSON_DIAGNOSTICS 1
|
||||||
#include <nlohmann/json.hpp>
|
#include <nlohmann/json.hpp>
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
@@ -105,7 +108,12 @@ configuration configuration::read_user_configuration()
|
|||||||
if (json["application"].is_string())
|
if (json["application"].is_string())
|
||||||
result.application.push_back(json["application"]);
|
result.application.push_back(json["application"]);
|
||||||
else
|
else
|
||||||
result.application = json["application"];
|
{
|
||||||
|
for(const auto& i: json["application"])
|
||||||
|
{
|
||||||
|
result.application.push_back(i);
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
catch (const std::exception & e)
|
catch (const std::exception & e)
|
||||||
|
|||||||
Reference in New Issue
Block a user