From da61621a62953f476bb68a53e4ae05e14c5b82f2 Mon Sep 17 00:00:00 2001 From: TC Date: Sat, 6 Feb 2021 22:22:49 +0100 Subject: [PATCH] Check updates after 2s --- index.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/index.js b/index.js index 7c452a06..cf9dea04 100644 --- a/index.js +++ b/index.js @@ -217,7 +217,10 @@ app.on("ready", () => { }); if (!is.dev() && config.get("options.autoUpdates")) { - autoUpdater.checkForUpdatesAndNotify(); + const updateTimeout = setTimeout(() => { + autoUpdater.checkForUpdatesAndNotify(); + clearTimeout(updateTimeout); + }, 2000); autoUpdater.on("update-available", () => { const downloadLink = "https://github.com/th-ch/youtube-music/releases/latest";