From 472a46f0a81451a4a4b127d273f3c1f8075e3fc5 Mon Sep 17 00:00:00 2001 From: smartfridge <37928912+smartfrigde@users.noreply.github.com> Date: Sat, 8 May 2021 23:26:53 +0200 Subject: [PATCH] Partially fix invites on Windows --- main.js | 4 ++++ preload.js | 1 - 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/main.js b/main.js index a5bcfa6..dd0ff40 100644 --- a/main.js +++ b/main.js @@ -114,6 +114,10 @@ app.whenReady().then(() => { // Approves the permissions request callback(true); } + if (!url.startsWith("discord://")) { + // Denies the permissions request + return callback(false); + } }); app.on("activate", function () { // On macOS it's common to re-create a window in the app when the diff --git a/preload.js b/preload.js index de85cf9..96a9877 100644 --- a/preload.js +++ b/preload.js @@ -5,7 +5,6 @@ const { remote } = require("electron"); window.addEventListener('DOMContentLoaded', () => { new customTitlebar.Titlebar({ backgroundColor: customTitlebar.Color.fromHex("#202225"), - menu: false, }); /**