Added contentOnly query to send html content as json

This commit is contained in:
Caleb Gardner
2024-08-06 16:46:25 -05:00
parent 0d40dd95c1
commit f99c9bd2fb
5 changed files with 18 additions and 17 deletions
+1 -5
View File
@@ -45,9 +45,5 @@ func filesRequest(w http.ResponseWriter, r *http.Request) {
return
}
}
if r.URL.Query().Get("contentOnly") == "true" {
w.Write([]byte(pageContent))
} else {
sendIndexWithContent(w, pageContent, "Files", "")
}
sendContent(w, r, pageContent, "Files", "")
}