diff --git a/server/db/job_daemon.js b/server/db/job_daemon.js index 6a5504c..5d12056 100644 --- a/server/db/job_daemon.js +++ b/server/db/job_daemon.js @@ -525,7 +525,7 @@ async function getWebsiteScreenshot(url, dest, filename, delay) { filehandler.checkDirectory(dest); const page = await browser.newPage(); - await page.goto(url, { waitUntil: 'domcontentloaded' }); + await page.goto(url, { waitUntil: 'networkidle0' }); //Wait slightly longer just in case await new Promise(resolve => setTimeout(resolve, parseInt(delay * 1000)));