Skip to content
Snippets Groups Projects
Commit 3f088fa8 authored by Adrien Béraud's avatar Adrien Béraud
Browse files

TransferManager: create link in proper direction

Change-Id: Iee0494e053a2e897ab1849f5deaeb240f9cc5a6f
parent 205904ed
Branches
Tags
No related merge requests found
......@@ -567,7 +567,7 @@ TransferManager::onIncomingProfile(const std::shared_ptr<dhtnet::ChannelSocket>&
std::filesystem::rename(path, destPath);
if (!pimpl->accountUri_.empty() && uri == pimpl->accountUri_) {
// If this is the account profile, link or copy it to the account profile path
if (!fileutils::createFileLink(destPath, pimpl->accountProfilePath_)) {
if (!fileutils::createFileLink(pimpl->accountProfilePath_, destPath)) {
std::error_code ec;
std::filesystem::copy_file(destPath, pimpl->accountProfilePath_, ec);
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment