mirror of
https://github.com/MihailRis/voxelcore.git
synced 2026-10-10 21:41:50 +00:00
dynamic::Value simplified
This commit is contained in:
parent
8e83a07094
commit
a4c21984d5
26 changed files with 230 additions and 297 deletions
|
|
@ -76,10 +76,10 @@ void langs::loadLocalesInfo(const fs::path& resdir, std::string& fallback) {
|
|||
if (langs) {
|
||||
std::cout << "locales ";
|
||||
for (auto& entry : langs->values) {
|
||||
auto langInfo = entry.second.get();
|
||||
auto langInfo = entry.second;
|
||||
|
||||
std::string name;
|
||||
if (auto mapptr = std::get_if<dynamic::Map*>(&langInfo->value)) {
|
||||
if (auto mapptr = std::get_if<dynamic::Map_sptr>(&langInfo)) {
|
||||
name = (*mapptr)->get("name", "none"s);
|
||||
} else {
|
||||
continue;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue