mirror of
https://github.com/qbittorrent/qBittorrent.git
synced 2025-12-18 06:28:03 -06:00
Update the UI when trackers or Url seeds are added either via the WebUI or via merging duplicate torrents.
This commit is contained in:
@@ -354,17 +354,9 @@ void WebApplication::action_command_addTrackers()
|
||||
QString hash = request().posts["hash"];
|
||||
|
||||
if (!hash.isEmpty()) {
|
||||
QTorrentHandle h = QBtSession::instance()->getTorrentHandle(hash);
|
||||
|
||||
if (h.is_valid() && h.has_metadata()) {
|
||||
QString urls = request().posts["urls"];
|
||||
QStringList list = urls.split('\n');
|
||||
|
||||
foreach (const QString& url, list) {
|
||||
announce_entry e(url.toStdString());
|
||||
h.add_tracker(e);
|
||||
}
|
||||
}
|
||||
QString urls = request().posts["urls"];
|
||||
QStringList list = urls.split('\n');
|
||||
QBtSession::instance()->addTrackersAndUrlSeeds(hash, list, QStringList());
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user