mirror of
https://github.com/qbittorrent/qBittorrent
synced 2025-07-29 19:18:42 -07:00
Fix root folder being cut off if the torrent comes from a scanned folder (Christian Kandeler)
This commit is contained in:
parent
e7abeb9bd4
commit
feeecbf395
1 changed files with 3 additions and 3 deletions
|
@ -2472,12 +2472,12 @@ QString QBtSession::getSavePath(const QString &hash, bool fromScanDir, QString f
|
||||||
qDebug("SavePath got from persistant data is %s", qPrintable(savePath));
|
qDebug("SavePath got from persistant data is %s", qPrintable(savePath));
|
||||||
bool append_root_folder = false;
|
bool append_root_folder = false;
|
||||||
if(savePath.isEmpty()) {
|
if(savePath.isEmpty()) {
|
||||||
if(fromScanDir && m_scanFolders->downloadInTorrentFolder(filePath))
|
if(fromScanDir && m_scanFolders->downloadInTorrentFolder(filePath)) {
|
||||||
savePath = QFileInfo(filePath).dir().path();
|
savePath = QFileInfo(filePath).dir().path();
|
||||||
else {
|
} else {
|
||||||
savePath = defaultSavePath;
|
savePath = defaultSavePath;
|
||||||
append_root_folder = true;
|
|
||||||
}
|
}
|
||||||
|
append_root_folder = true;
|
||||||
}
|
}
|
||||||
if(!fromScanDir && appendLabelToSavePath) {
|
if(!fromScanDir && appendLabelToSavePath) {
|
||||||
const QString label = TorrentPersistentData::getLabel(hash);
|
const QString label = TorrentPersistentData::getLabel(hash);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue