feat(client): throw when we don't have required resources files

pull/105/head
Alexis 2018-11-23 19:31:40 +01:00
parent 2e1f8b2fc5
commit 2c2a0473f4
1 changed files with 3 additions and 0 deletions

View File

@ -41,6 +41,9 @@ waybar::Client::Client(int argc, char* argv[])
"/etc/xdg/waybar/style.css", "/etc/xdg/waybar/style.css",
"./resources/style.css", "./resources/style.css",
}); });
if (css_file.empty() || config_file.empty()) {
throw std::runtime_error("Missing required resources files");
}
std::cout << "Resources files: " + config_file + ", " + css_file << std::endl; std::cout << "Resources files: " + config_file + ", " + css_file << std::endl;
} }