diff --git a/lib/libimhex/source/api/theme_manager.cpp b/lib/libimhex/source/api/theme_manager.cpp index 2679d2b22..d36e017ef 100644 --- a/lib/libimhex/source/api/theme_manager.cpp +++ b/lib/libimhex/source/api/theme_manager.cpp @@ -122,7 +122,7 @@ namespace hex { } } - if (theme.contains("colors")) { + if (theme.contains("colors") && !s_themeHandlers.empty()) { for (const auto&[type, content] : theme["colors"].items()) { if (!s_themeHandlers.contains(type)) { log::warn("No theme handler found for '{}'", type); @@ -147,7 +147,7 @@ namespace hex { } } - if (theme.contains("styles")) { + if (theme.contains("styles") && !s_styleHandlers.empty()) { for (const auto&[type, content] : theme["styles"].items()) { if (!s_styleHandlers.contains(type)) { log::warn("No style handler found for '{}'", type); diff --git a/plugins/builtin/source/content/themes.cpp b/plugins/builtin/source/content/themes.cpp index b766ebc3c..cdbed1403 100644 --- a/plugins/builtin/source/content/themes.cpp +++ b/plugins/builtin/source/content/themes.cpp @@ -8,7 +8,6 @@ #include #include -#include #include #include