From 1786239f6ad1c0c46e395781d9d11506bf50e82f Mon Sep 17 00:00:00 2001 From: Bsian Date: Wed, 10 Jun 2020 14:13:38 +0100 Subject: [PATCH] Fix status checker --- src/commands/whois.ts | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/commands/whois.ts b/src/commands/whois.ts index 77c5156..4e7c9b6 100644 --- a/src/commands/whois.ts +++ b/src/commands/whois.ts @@ -65,9 +65,7 @@ export default class Whois extends Command { break; } } - if (member.status) { - embed.addField('Status', `${member.status[0].toUpperCase()}${member.status.slice(1)}`, true); - } + embed.addField('Status', member.status === 'dnd' ? 'Do Not Disturb' : `${member.status?.substring(0, 1).toUpperCase()}${member.status?.substring(1)}` || 'Unknown', true); if (member.bot) { embed.addField('Platform', 'API/WebSocket', true); } else if (member.clientStatus?.web === 'online' || member.clientStatus?.web === 'idle' || member.clientStatus?.web === 'dnd') {