diff --git a/assets/js/userarea.js b/assets/js/userarea.js index 9a13b2d..67a48aa 100644 --- a/assets/js/userarea.js +++ b/assets/js/userarea.js @@ -1,7 +1,7 @@ import "../scss/frontend.scss"; import "../css/userarea.css"; -import { getCookie } from "./api"; +import { getCookie, getElementById } from "./api"; import { Tab } from "bootstrap"; import DataTable from "datatables.net-dt"; @@ -129,10 +129,11 @@ function uploadFile(file, progressBar, thumbnail) { xhr.onload = () => { if (xhr.status === 201) { const response = JSON.parse(xhr.responseText); - const thumbnailUrl = response.thumbnailUrl; - thumbnail.src = thumbnailUrl; progressBar.classList.add("bg-success"); progressBar.textContent = "Success!"; + + // TODO: Check API until the first resolution is available + } else { progressBar.classList.add("bg-danger"); progressBar.textContent = "Error!";