From b93edb58939f4e47e0cd87b8e504de6989fa48a2 Mon Sep 17 00:00:00 2001 From: Matthew R Date: Fri, 5 Mar 2021 22:46:00 -0500 Subject: [PATCH] fixes or whateva --- src/class/Util.ts | 5 +++++ src/commands/whois.ts | 11 +---------- 2 files changed, 6 insertions(+), 10 deletions(-) diff --git a/src/class/Util.ts b/src/class/Util.ts index 6a06077..da94ea2 100644 --- a/src/class/Util.ts +++ b/src/class/Util.ts @@ -303,4 +303,9 @@ export default class Util { } return `${i}th`; } + + public capsFirstLetter(string?: string): string | void { + if (typeof string !== 'string') return undefined; + return string.substring(0, 1).toUpperCase() + string.substring(1); + } } diff --git a/src/commands/whois.ts b/src/commands/whois.ts index eca5534..b9e6523 100644 --- a/src/commands/whois.ts +++ b/src/commands/whois.ts @@ -74,7 +74,7 @@ export default class Whois extends Command { break; } } - embed.addField('Status', member.status === 'dnd' ? 'Do Not Disturb' : this.capsFirstLetter(member.status) || 'Offline', true); + embed.addField('Status', member.status === 'dnd' ? 'Do Not Disturb' : this.client.util.capsFirstLetter(member.status) || 'Offline', true); embed.addField('Joined At', `${moment(new Date(member.joinedAt)).format('dddd, MMMM Do YYYY, h:mm:ss A')} ET`, true); embed.addField('Created At', `${moment(new Date(member.user.createdAt)).format('dddd, MMMM Do YYYY, h:mm:ss A')} ET`, true); const score = await this.client.db.Score.findOne({ userID: member.id }).lean().exec(); @@ -223,13 +223,4 @@ export default class Whois extends Command { return this.client.util.handleError(err, message, this); } } - - public resolveStaffInformation(id: string) { - return null; // acknowledgements.find((m) => m.id === id); - } - - public capsFirstLetter(string?: string): string | void { - if (typeof string !== 'string') return undefined; - return string.substring(0, 1).toUpperCase() + string.substring(1); - } }