fix: make sure to not skip out on ENOENT
This commit is contained in:
parent
a3a2e47f58
commit
ff7e8a19ac
1 changed files with 1 additions and 1 deletions
|
@ -82,7 +82,7 @@ function initRPC(clientID: string): void {
|
|||
|
||||
// Log in to the RPC Client, and check whether or not it errors.
|
||||
rpc.login(clientID).catch(error => {
|
||||
if (reconnect) return;
|
||||
if (reconnect && !error.message.includes('ENOENT')) return;
|
||||
if (error.message.includes('ENOENT')) window.showErrorMessage('No Discord Client detected!');
|
||||
else window.showErrorMessage(`Could not connect to discord via rpc: ${error.message}`);
|
||||
});
|
||||
|
|
Loading…
Reference in a new issue