From 8ceb409dc3540a5bf57fc91f88325faeb7f1831d Mon Sep 17 00:00:00 2001 From: Peter Edmond Date: Tue, 3 Jun 2025 15:51:53 +0100 Subject: [PATCH] Adjusted comments to fill if the calculated number of respondents in the cohort is greater than 7 rather than if the number of comments is more than 7. Note that this is done client side so is technically unsafe! --- fillcomments.js | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/fillcomments.js b/fillcomments.js index 4e01285..f8388b6 100644 --- a/fillcomments.js +++ b/fillcomments.js @@ -26,6 +26,12 @@ function doComments(id,qid) { .then(data => { // Output result //console.log(data); + const recordNo = parseInt(document.getElementById('record_no').textContent, 10); + if (recordNo <8){ + return; + } + + const parsed = JSON.parse(data); const div = document.getElementById(id);