From 63e86fbe9ef85a1eca6cad7805a4b235b385e95c Mon Sep 17 00:00:00 2001 From: Alexis Date: Fri, 26 Oct 2018 10:12:34 +0200 Subject: [PATCH] fix: check type --- src/ALabel.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/ALabel.cpp b/src/ALabel.cpp index 00b37d74..70d17655 100644 --- a/src/ALabel.cpp +++ b/src/ALabel.cpp @@ -40,7 +40,7 @@ std::string waybar::ALabel::getIcon(uint16_t percentage, const std::string& alt) { auto format_icons = config_["format-icons"]; if (format_icons.isObject()) { - if (!alt.empty() && format_icons[alt]) { + if (!alt.empty() && format_icons[alt].isString()) { format_icons = format_icons[alt]; } else { format_icons = format_icons["default"];