Re-enable magnet button

This commit is contained in:
2025-10-14 12:57:30 +02:00
parent 008ea9c43d
commit 8d434cc114

View File

@@ -119,21 +119,14 @@ class trdom_torrentcontrol extends EventTarget {
e.stopPropagation(); e.stopPropagation();
break; break;
case 'magnet': case 'magnet':
/*let magneturl; e.stopPropagation();
for (const [srv, data] of Object.entries(this.#getKnownTorrents()[this.#hash].servers)) { if (this.magnet != null) {
if (data.magnetLink != null) { this.#server.torrent_add_url(this.magnet, true, null);
magneturl = data.magnetLink;
break;
}
}
if (magneturl != null) {
this.#server.torrent_add_url(magneturl, false, null);
} }
else { else {
this.#log(3, `Couldn't find magnet link! ${JSON.stringify(this.#getKnownTorrents()[this.#hash].servers)}`); this.#log(3, 'Couldn\'t find magnet link!');
}*/ window.alert('Couldn\'t find magnet link!');
e.stopPropagation(); }
window.alert('not implemented');
break; break;
case 'download': case 'download':
e.stopPropagation(); e.stopPropagation();