impr: Harden settings system to not crash ImHex when having outdated configs

Fixes #1514
This commit is contained in:
WerWolv
2024-02-03 12:16:36 +01:00
parent 2ea0bbe5ca
commit a03e8dd879
22 changed files with 106 additions and 93 deletions

View File

@@ -287,7 +287,7 @@ namespace hex::plugin::builtin {
static bool alwaysShowProviderTabs = false;
EventSettingsChanged::subscribe([] {
alwaysShowProviderTabs = ContentRegistry::Settings::read("hex.builtin.setting.interface", "hex.builtin.setting.interface.always_show_provider_tabs", false);
alwaysShowProviderTabs = ContentRegistry::Settings::read<bool>("hex.builtin.setting.interface", "hex.builtin.setting.interface.always_show_provider_tabs", false);
});
ContentRegistry::Interface::addToolbarItem([] {