From 72764f7e141b390c19548ea17a5c75a35dd53bcc Mon Sep 17 00:00:00 2001 From: Bsian Date: Tue, 29 Oct 2019 16:25:41 +0000 Subject: [PATCH] Promise rejection wording change --- src/class/Util.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/class/Util.ts b/src/class/Util.ts index c952600..7911e18 100644 --- a/src/class/Util.ts +++ b/src/class/Util.ts @@ -158,7 +158,7 @@ export default class Util { public async createModerationLog(user: string, moderator: Member, type: number, reason?: string, duration?: number): Promise { const moderatorID = moderator.id; const account = await this.client.db.Account.findOne({ $or: [{ username: user }, { userID: user }] }); - if (!account) return Promise.reject(new Error('Account not found')); + if (!account) return Promise.reject(new Error(`Account ${user} not found`)); const { username, userID } = account; const logInput: { username: string, userID: string, logID: string, moderatorID: string, reason?: string, type: number, date: Date, expiration?: { date: Date, processed: boolean }} = { username, userID, logID: uuid(), moderatorID, type, date: new Date(),