update HTML page

This commit is contained in:
Francesco Mangiacrapa 2024-04-22 14:57:28 +02:00
parent 9ec1dcf9a0
commit 9203782e49
2 changed files with 3 additions and 2 deletions

View File

@ -42,7 +42,8 @@ public class FetchPDF {
}
public synchronized int incrementAttempt() {
return attempt++;
attempt++;
return attempt;
}

View File

@ -48,7 +48,6 @@ public class HTML_Page {
+ " <script type=\"text/javascript\">\n"
+ " async function fetchPDF_URL() {\n"
+ " try {\n"
+ "\n"
+ " const response = await fetch('"+viewPdfURL+"');\n"
+ " console.log(\"polling response\");\n"
+ " return response.json();\n"
@ -58,6 +57,7 @@ public class HTML_Page {
+ " }\n"
+ " async function playPDFPoll() {\n"
+ " const response_object = await fetchPDF_URL();\n"
+ " console.log(\"response is: \" + response_object);\n"
+ " let isJsonResponse = isJsonString(response_object);\n"
+ " if (isJsonResponse) {\n"
+ " console.log(\"json response \" + response_object);\n"