diff --git a/static/js/download.js b/static/js/download.js index 555baa5..01e1a97 100644 --- a/static/js/download.js +++ b/static/js/download.js @@ -1,7 +1,9 @@ let updateInterval; document.addEventListener("DOMContentLoaded", () => { - const table = document.getElementById("download_contents").getElementsByTagName("tbody")[0]; + const downloadContents = document.getElementById("download_contents"); + if (!downloadContents) { return; } + const table = downloadContents.getElementsByTagName("tbody")[0]; if (table.children.length === 0) { return; } updateInterval = setInterval(() => {