From 1f235bb8068516d3d6901ed7d1323fffb84db7ac Mon Sep 17 00:00:00 2001 From: Miikka Virtanen Date: Wed, 15 Feb 2017 01:04:57 +0200 Subject: [PATCH] Fix2 --- src/index.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/index.js b/src/index.js index bc0a6e9..25c598a 100644 --- a/src/index.js +++ b/src/index.js @@ -126,16 +126,16 @@ Here's what their message contained: const memberPromise = (mainGuild ? mainGuild.getRESTMember(msg.author.id) : Promise.resolve()); threadInitDonePromise = memberPromise + .catch(err => { + console.log(`Member ${msg.author.id} not found in main guild ${config.mainGuildId}`); + console.error(err); + }) .then(member => { const mainGuildNickname = (member != null ? (member.nick || member.username) : 'UNKNOWN'); const accountAge = humanizeDuration(Date.now() - msg.author.createdAt, {largest: 2}); const infoHeader = `ACCOUNT AGE **${accountAge}**, ID **${msg.author.id}**, NICKNAME **${mainGuildNickname}**, LOGS **${userLogs.length}**\n-------------------------------`; bot.createMessage(thread.channelId, infoHeader); - }) - .catch(err => { - console.log(`Member ${msg.author.id} not found in main guild ${config.mainGuildId}`); - console.error(err); }); // Ping mods of the new thread