This commit is contained in:
Your Name
2025-05-04 19:56:52 +12:00
parent 27e5cce367
commit 008cf59c48
7 changed files with 98 additions and 20 deletions

View File

@@ -46,9 +46,9 @@ namespace localfile {
namespace localpath {
std::string server(const std::string &server_name) {
if (server_name.empty()) return "";
for (auto &dir : gConfig().get_local_server_definition_paths())
if (fs::exists(dir + server_name))
return dir + server_name;
for (std::filesystem::path dir : gConfig().get_local_server_definition_paths())
if (fs::exists(dir / server_name))
return dir / server_name;
return "";
}