Update Modified Info When Files Are Fetched

This commit is contained in:
Leo Herzog
2020-10-02 13:58:06 -04:00
parent 13ba4a6770
commit 6b2e3a4557
3 changed files with 5 additions and 3 deletions

View File

@@ -33483,9 +33483,9 @@ async function addCurrentTrackers() {
let response = await fetch("https://newtrackon.com/api/100"); // get trackers with 100% uptime
let trackers = await response.text();
parsed.announce = parsed.announce.concat(trackers.split('\n\n'));
parsed.announce = parsed.announce.filter((v,i) => v && parsed.announce.indexOf(v) === i); // remove duplicates and empties
parsed.announce.push("http://bt1.archive.org:6969/announce");
parsed.announce.push("http://bt2.archive.org:6969/announce");
parsed.announce = parsed.announce.filter((v,i) => v && parsed.announce.indexOf(v) === i); // remove duplicates and empties
updateModified();
}
catch(e) {
@@ -33534,6 +33534,7 @@ function getFilesFromPeers() {
parsed.length = torrent.length;
parsed.lastPieceLength = torrent.lastPieceLength;
getFiles.innerHTML = '<span class="fad fa-chart-network"></span>';
updateModified();
display();
torrent.destroy();
});

2
bundle.min.js vendored

File diff suppressed because one or more lines are too long

View File

@@ -296,9 +296,9 @@ async function addCurrentTrackers() {
let response = await fetch("https://newtrackon.com/api/100"); // get trackers with 100% uptime
let trackers = await response.text();
parsed.announce = parsed.announce.concat(trackers.split('\n\n'));
parsed.announce = parsed.announce.filter((v,i) => v && parsed.announce.indexOf(v) === i); // remove duplicates and empties
parsed.announce.push("http://bt1.archive.org:6969/announce");
parsed.announce.push("http://bt2.archive.org:6969/announce");
parsed.announce = parsed.announce.filter((v,i) => v && parsed.announce.indexOf(v) === i); // remove duplicates and empties
updateModified();
}
catch(e) {
@@ -347,6 +347,7 @@ function getFilesFromPeers() {
parsed.length = torrent.length;
parsed.lastPieceLength = torrent.lastPieceLength;
getFiles.innerHTML = '<span class="fad fa-chart-network"></span>';
updateModified();
display();
torrent.destroy();
});