fix memory leak

This commit is contained in:
2025-04-29 15:08:44 -07:00
parent 174a8a54c7
commit 747bef3c93

View File

@ -132,14 +132,15 @@ async function checkForUpdates(config) {
} }
// Main loop // Main loop
async function poll() {
for (const config of configs) {
await checkForUpdates(config);
}
setTimeout(poll, pollIntervalMs);
}
(async () => { (async () => {
console.log('🚀 Starting poller...'); console.log('🚀 Starting poller...');
for (const config of configs) { await poll();
await checkForUpdates(config);
}
setInterval(async () => {
for (const config of configs) {
await checkForUpdates(config);
}
}, pollIntervalMs);
})(); })();