diff --git a/front/static/edit_report.html b/front/static/edit_report.html
index 9cf6b27..2ccac85 100644
--- a/front/static/edit_report.html
+++ b/front/static/edit_report.html
@@ -45,6 +45,9 @@
Your Report History
+
+
+
diff --git a/front/static/js/viewHistory.js b/front/static/js/viewHistory.js
index fdf1d2e..fbbdf9f 100644
--- a/front/static/js/viewHistory.js
+++ b/front/static/js/viewHistory.js
@@ -290,14 +290,19 @@ function createReportForm(parsedData, type) {
function displayListOfReports(parsedData) {
const reports = parsedData.reports;
+ const cardBody = document.querySelector(".card-body");
const table = document.querySelector("table");
+ console.log(cardBody);
+ console.log(cardBody.firstElementChild);
+ cardBody.removeChild(cardBody.firstElementChild); // remove loading spinner
+
if (reports.length === 0) {
- const cardBody = document.querySelector(".card-body");
- const h4 = document.createElement("h4");
- h4.innerHTML = "No reports found.";
- h4.classList.add("text-center");
- cardBody.insertBefore(h4, table);
+ cardBody.removeChild(table);
+ const h5 = document.createElement("h5");
+ h5.innerHTML = "No reports found.";
+ h5.classList.add("text-center");
+ cardBody.appendChild(h5);
} else {
const tbody = document.querySelector("tbody");