mirror of
https://github.com/qbittorrent/qBittorrent.git
synced 2025-12-17 22:18:05 -06:00
Setting for creating subfolder on multifile torrents. Closes #588.
This commit is contained in:
committed by
Vladimir Golovnev (Glassez)
parent
07af8c9648
commit
4b2d8a7941
@@ -1652,6 +1652,11 @@ bool Session::addTorrent_impl(AddTorrentData addData, const MagnetUri &magnetUri
|
||||
p = magnetUri.addTorrentParams();
|
||||
}
|
||||
else if (torrentInfo.isValid()) {
|
||||
if (!addData.resumed && !addData.createSubfolder && torrentInfo.filesCount() > 1) {
|
||||
libtorrent::file_storage files = torrentInfo.files();
|
||||
files.set_name("");
|
||||
torrentInfo.remapFiles(files);
|
||||
}
|
||||
// Metadata
|
||||
if (!addData.resumed && !addData.hasSeedStatus)
|
||||
findIncompleteFiles(torrentInfo, savePath);
|
||||
|
||||
Reference in New Issue
Block a user