Added debug log for jsdom window closing.

This commit is contained in:
DebaucheryLibrarian 2021-12-01 23:44:25 +01:00
parent eafa144104
commit 61daf5f037
1 changed files with 4 additions and 0 deletions

View File

@ -128,6 +128,10 @@ async function scrapeRelease(baseRelease, entitiesBySlug, type = 'scene') {
const pathname = new URL(baseRelease.url).pathname.replace(/\//g, '_'); const pathname = new URL(baseRelease.url).pathname.replace(/\//g, '_');
if (windows.has(pathname)) {
logger.debug(`Closing window for ${pathname}`);
}
windows.get(pathname)?.close(); windows.get(pathname)?.close();
windows.delete(pathname); windows.delete(pathname);