root file/dir

This commit is contained in:
Talyx
2022-02-24 18:12:26 +03:00
parent 1312e3e5de
commit 08903bfa15

View File

@@ -417,8 +417,8 @@ bool ServerConfig::checkFileAndDir(location *loc)
if (!root.empty()) if (!root.empty())
{ {
if (isDir(root) != 0) if (isDir(root) != 0 && isFile(root) != 0)
throw ConfigException("Directory " + root + " not found!"); throw ConfigException("File or directory " + root + " not found!");
} }
if (!upload_dir.empty()) if (!upload_dir.empty())
{ {