Proper formatting

This commit is contained in:
Oskar Carl 2021-01-24 18:32:05 +01:00
parent 14f626d422
commit e8278431d2
No known key found for this signature in database
GPG Key ID: 25FB862C4317BCA4

View File

@ -241,9 +241,9 @@ auto waybar::Client::setupConfig(const std::string &config_file) -> void {
}
std::string str((std::istreambuf_iterator<char>(file)), std::istreambuf_iterator<char>());
util::JsonParser parser;
Json::Value tmp_config_ = parser.parse(str);
Json::Value tmp_config_ = parser.parse(str);
if (tmp_config_["include"].isArray()) {
for (const auto& include : tmp_config_["include"]) {
for (const auto &include : tmp_config_["include"]) {
spdlog::info("Including resource file: {}", include.asString());
setupConfig(getValidPath({include.asString()}));
}
@ -252,7 +252,7 @@ auto waybar::Client::setupConfig(const std::string &config_file) -> void {
}
auto waybar::Client::mergeConfig(Json::Value &a_config_, Json::Value &b_config_) -> void {
for (const auto& key : b_config_.getMemberNames()) {
for (const auto &key : b_config_.getMemberNames()) {
if (a_config_[key].type() == Json::objectValue && b_config_[key].type() == Json::objectValue) {
mergeConfig(a_config_[key], b_config_[key]);
} else {