From 591dfdd0c5af2fd93aa94babc5a573b058dad92e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Henrik=20Rydg=C3=A5rd?= Date: Wed, 31 Jan 2024 12:20:46 +0100 Subject: [PATCH] Fix bug with empty themes showing up --- UI/Theme.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/UI/Theme.cpp b/UI/Theme.cpp index c59a591275..91c7d10dbf 100644 --- a/UI/Theme.cpp +++ b/UI/Theme.cpp @@ -114,6 +114,11 @@ static void LoadThemeInfo(const std::vector &directories) { // Alright, let's loop through the sections and see if any is a theme. for (size_t i = 0; i < ini.Sections().size(); i++) { Section §ion = *(ini.Sections()[i].get()); + + if (section.name().empty()) { + continue; + } + ThemeInfo info; section.Get("Name", &info.name, section.name().c_str());