hopefully force shard to quit if IPC closes

This commit is contained in:
Erik 2023-04-05 17:33:46 +03:00
parent 85448f9616
commit 289d3c7f3b
Signed by: Navy.gif
GPG Key ID: 2532FBBB61C65A68
2 changed files with 13 additions and 13 deletions

View File

@ -5,17 +5,17 @@ const { SlashCommand, CommandError } = require("../../../interfaces");
const Constants = { const Constants = {
Badges: { Badges: {
DISCORD_EMPLOYEE: Emojis['discord-staff'], Staff: Emojis['discord-staff'],
DISCORD_PARTNER: Emojis['discord-partner'], Partner: Emojis['discord-partner'],
HYPESQUAD_EVENTS: Emojis['hypesquad-events'], Hypesquad: Emojis['hypesquad-events'],
BUGHUNTER_LEVEL_1: Emojis['bughunter'], //eslint-disable-line dot-notation BugHunterLevel1: Emojis['bughunter'], //eslint-disable-line dot-notation
BUGHUNTER_LEVEL_2: Emojis['bughunter-gold'], BugHunterLevel2: Emojis['bughunter-gold'],
HOUSE_BRAVERY: Emojis['hypesquad-bravery'], HypeSquadOnlineHouse1: Emojis['hypesquad-bravery'],
HOUSE_BRILLIANCE: Emojis['hypesquad-brilliance'], HypeSquadOnlineHouse2: Emojis['hypesquad-brilliance'],
HOUSE_BALANCE: Emojis['hypesquad-balance'], HypeSquadOnlineHouse3: Emojis['hypesquad-balance'],
EARLY_SUPPORTER: Emojis['early-supporter'], PremiumEarlySupporter: Emojis['early-supporter'],
EARLY_VERIFIED_BOT_DEVELOPER: Emojis['bot-developer'], VerifiedDeveloper: Emojis['bot-developer'],
DISCORD_CERTIFIED_MODERATOR: Emojis['certified-moderator'] CertifiedModerator: Emojis['certified-moderator']
} }
}; };

View File

@ -16,8 +16,8 @@ class Logger {
message = `${chalk.bold(`[${this.name.substring(0, 6)}]`)} ${message}`; message = `${chalk.bold(`[${this.name.substring(0, 6)}]`)} ${message}`;
// eslint-disable-next-line no-console // eslint-disable-next-line no-console, no-process-exit
if (!process.send || !process.connected) console.log(message); if (!process.send || !process.connected) process.exit(); // Child-process disconnected for some reason //console.log(message);
else process.send({ _logger: true, message, ...opts }); else process.send({ _logger: true, message, ...opts });
//return this.client.intercom.send('logger', { message, ...opts }); //return this.client.intercom.send('logger', { message, ...opts });
} }