diff options
| author | AltoXorg <56553686+Alto1772@users.noreply.github.com> | 2025-08-02 12:31:30 +0800 |
|---|---|---|
| committer | Lywx <kiritodev01@gmail.com> | 2025-08-02 21:26:25 -0600 |
| commit | cd92cc0f161c5e79e36f5dda0d0029edd3fc8d50 (patch) | |
| tree | 589a572fc43f57169aa15487c652aaa716c1a6a5 | |
| parent | 6b9d760594bb07198c4bf43076c9eef0aa20f958 (diff) | |
empty src/dest paths workaround
| -rw-r--r-- | src/Companion.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/Companion.cpp b/src/Companion.cpp index a38a312..eb4b2b2 100644 --- a/src/Companion.cpp +++ b/src/Companion.cpp @@ -1372,7 +1372,7 @@ std::optional<std::tuple<std::string, YAML::Node>> Companion::RegisterAsset(cons spdlog::set_pattern(regular); SPDLOG_INFO("------------------------------------------------"); spdlog::set_pattern(line); - + return entry; } @@ -1590,13 +1590,13 @@ std::string Companion::RelativePath(const std::string& path) const { } std::string Companion::RelativePathToDestDir(const std::string& path) const { - std::string doutput = relative(path, this->gDestinationDirectory).string(); + std::string doutput = fs::path(path).lexically_relative(this->gDestinationDirectory).string(); ConvertWinToUnixSlash(doutput); return doutput; } std::string Companion::RelativePathToSrcDir(const std::string& path) const { - std::string doutput = relative(path, this->gSourceDirectory).string(); + std::string doutput = fs::path(path).lexically_relative(this->gSourceDirectory).string(); ConvertWinToUnixSlash(doutput); return doutput; } |
