mirror of
https://github.com/qbittorrent/qBittorrent.git
synced 2026-01-02 13:48:05 -06:00
Fix "Open destination folder" that would open a subfolder instead (closes #607510)
This commit is contained in:
@@ -450,15 +450,6 @@ bool QTorrentHandle::priv() const {
|
||||
return h.get_torrent_info().priv();
|
||||
}
|
||||
|
||||
QString QTorrentHandle::root_path() const {
|
||||
Q_ASSERT(h.is_valid());
|
||||
if(num_files() == 0) return "";
|
||||
QStringList path_list = misc::toQStringU(h.get_torrent_info().file_at(0).path.string()).split("/");
|
||||
if(path_list.size() > 1)
|
||||
return save_path()+"/"+path_list.first();
|
||||
return save_path();
|
||||
}
|
||||
|
||||
QString QTorrentHandle::firstFileSavePath() const {
|
||||
Q_ASSERT(h.is_valid());
|
||||
Q_ASSERT(has_metadata());
|
||||
|
||||
Reference in New Issue
Block a user