From 944e6c5db428950a656b65b072cff9c27c1f813b Mon Sep 17 00:00:00 2001 From: aandrew-me Date: Sun, 26 Oct 2025 12:09:33 +0300 Subject: [PATCH] Minor changes --- main.js | 8 ++++---- src/renderer.js | 1 + 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/main.js b/main.js index ff6305e..6a87e66 100644 --- a/main.js +++ b/main.js @@ -14,7 +14,7 @@ const fs = require("fs"); const path = require("path"); const DownloadHistory = require("./src/history"); autoUpdater.autoDownload = false; -/**@type {BrowserWindow} */ +/**@type {Electron.CrossProcessExports.BrowserWindow} */ let win = null; let secondaryWindow = null; let tray = null; @@ -57,7 +57,7 @@ function createWindow() { win.show(); autoUpdater.checkForUpdates().then(result => { - // Removing unnecesary files for windows + // Removing unnecessary files for windows if (result && process.platform === "win32") { if (result.updateInfo.version === app.getVersion()) { fs.readdir(path.join(process.env.LOCALAPPDATA, "ytdownloader-updater"), {encoding: "utf-8", withFileTypes: true}, (err, files) => { @@ -171,9 +171,9 @@ app.whenReady().then(() => { let trayInUse = false; // TODO: Find why tray icon isn't showing properly on gnome let icon; - if (process.platform == "win32") { + if (process.platform === "win32") { icon = path.join(__dirname, "resources/icon.ico"); - } else if (process.platform == "darwin") { + } else if (process.platform === "darwin") { icon = path.join(__dirname, "resources/icons/16x16.png"); } else { icon = path.join(__dirname, "resources/icons/256x256.png"); diff --git a/src/renderer.js b/src/renderer.js index 013acde..9e00852 100644 --- a/src/renderer.js +++ b/src/renderer.js @@ -433,6 +433,7 @@ class YtDownloaderApp { // Error details $(CONSTANTS.DOM_IDS.ERROR_DETAILS).addEventListener("click", (e) => { + // @ts-ignore clipboard.writeText(e.target.innerText); this._showPopup("Copied error details to clipboard."); });