Fixed env not working with non lowercase value

This commit is contained in:
Mint
2022-11-13 19:01:50 +09:00
parent 9c9434f4ba
commit 306dafc75a
+5 -2
View File
@@ -13,8 +13,11 @@ const EMBEDS = {
INVITE_INFO: (data: HybridInteractionMessage, locale: I18n) => { INVITE_INFO: (data: HybridInteractionMessage, locale: I18n) => {
const user = data.getUser(); const user = data.getUser();
let message; let message;
if (!(Environment.get().PRIVATE_BOT === 'true') || user != null && Users.isDeveloper(user.id)) if (!(Environment.get().PRIVATE_BOT.toLowerCase() === 'true') || (user != null && Users.isDeveloper(user.id)))
message = locale.__('invite.info', { BOT_NAME: DiscordProvider.client.user!.username, LINK: `https://discord.com/api/oauth2/authorize?client_id=${DiscordProvider.client.user?.id}&permissions=8&scope=bot%20applications.commands`}); message = locale.__('invite.info', {
BOT_NAME: DiscordProvider.client.user!.username,
LINK: `https://discord.com/api/oauth2/authorize?client_id=${DiscordProvider.client.user?.id}&permissions=8&scope=bot%20applications.commands`
});
return makeInfoEmbed({ return makeInfoEmbed({
title: `Invite`, title: `Invite`,