mirror of
https://github.com/Team-Neptune/DeepSea-Toolbox.git
synced 2024-11-26 22:00:34 +00:00
Relax config.json parsing restrictions
Sysmodules menu no longer fails if it can't parse the file
This commit is contained in:
parent
0356c59574
commit
2916c61ec6
@ -35,17 +35,12 @@ GuiSysmodule::GuiSysmodule() : Gui() {
|
||||
anyModulesPresent = false;
|
||||
|
||||
std::ifstream configFile("sdmc:/switch/KosmosToolbox/config.json");
|
||||
|
||||
if (configFile.fail()) {
|
||||
Gui::g_nextGui = GUI_MAIN;
|
||||
return;
|
||||
}
|
||||
|
||||
json configJson;
|
||||
|
||||
if (!configFile.fail()) {
|
||||
try {
|
||||
configFile >> configJson;
|
||||
} catch(json::parse_error& e) {
|
||||
return;
|
||||
} catch(json::parse_error& e) {}
|
||||
}
|
||||
|
||||
DIR *contents_dir = opendir(CONTENTS_PATH);
|
||||
|
Loading…
Reference in New Issue
Block a user