diff --git a/Makefile b/Makefile index 8bc8474..25b625c 100644 --- a/Makefile +++ b/Makefile @@ -22,7 +22,7 @@ DATA := data INCLUDES := include lib/zipper/include /lib/borealis/library/include/borealis/extern/nlohmann APP_TITLE := All-in-One Switch Updater APP_AUTHOR := HamletDuFromage -APP_VERSION := 2.10.0 +APP_VERSION := 2.10.1 TARGET := $(notdir $(CURDIR)) ROMFS := resources diff --git a/source/ams_tab.cpp b/source/ams_tab.cpp index 6286c03..f7a5fec 100644 --- a/source/ams_tab.cpp +++ b/source/ams_tab.cpp @@ -20,7 +20,7 @@ AmsTab::AmsTab(const bool erista) : brls::List() download::getRequest(AMS_URL, cfws); - CreateDownloadItems(cfws["Atmosphere"]); + CreateDownloadItems(cfws.find("Atmosphere") != cfws.end() ? cfws["Atmosphere"] : nlohmann::ordered_json::object()); description = new brls::Label( brls::LabelStyle::DESCRIPTION, @@ -38,18 +38,20 @@ AmsTab::AmsTab(const bool erista) : brls::List() }); this->addView(listItem); - CreateDownloadItems(cfws["DeepSea"], false); + CreateDownloadItems(cfws.find("DeepSea") != cfws.end() ? cfws["DeepSea"] : nlohmann::ordered_json::object()); - auto custom_pack = fs::parseJsonFile(CUSTOM_PACKS_PATH); - if (custom_pack.size() != 0) { - description = new brls::Label( - brls::LabelStyle::DESCRIPTION, - fmt::format("menus/ams_update/custom_packs_label"_i18n, CUSTOM_PACKS_PATH), - true - ); - this->addView(description); + if(cfws.size()) { + auto custom_pack = fs::parseJsonFile(CUSTOM_PACKS_PATH); + if (custom_pack.size() != 0) { + description = new brls::Label( + brls::LabelStyle::DESCRIPTION, + fmt::format("menus/ams_update/custom_packs_label"_i18n, CUSTOM_PACKS_PATH), + true + ); + this->addView(description); - CreateDownloadItems(custom_pack, true); + CreateDownloadItems(custom_pack, true); + } } } diff --git a/source/changelog_page.cpp b/source/changelog_page.cpp index 174dc5c..f9aca34 100644 --- a/source/changelog_page.cpp +++ b/source/changelog_page.cpp @@ -175,6 +175,9 @@ ChangelogPage::ChangelogPage() : AppletFrame(true, true) verTitles.push_back("v2.10.0"); changes.push_back("\uE016 Added support custom packs through a json file."); + verTitles.push_back("v2.10.1"); + changes.push_back("\uE016 Fixed crashes in airplane mode introduced in 2.10.0"); + for(int i = verTitles.size() -1 ; i >= 0; i--){ listItem = new brls::ListItem(verTitles[i]); change = changes[i];