diff --git a/static/js/download.js b/static/js/download.js index 70b40b5..555baa5 100644 --- a/static/js/download.js +++ b/static/js/download.js @@ -18,7 +18,7 @@ document.addEventListener("DOMContentLoaded", () => { for (const [index, offset] of info.offsets.entries()) { table.children[index].className = (offset > info.available) ? "unavailable" : ""; } - if (info.available === info.file.size) { + if (info.offsets.length === 0 || info.available >= info.offsets.at(-1)) { clearInterval(updateInterval); } })