From e922f78ef31f2c1ae726330dabbaccea9fe177a8 Mon Sep 17 00:00:00 2001 From: Miikka Virtanen Date: Sun, 1 Jan 2017 06:35:34 +0200 Subject: [PATCH] Fix undefined variable --- index.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/index.js b/index.js index 5a2b631..74a68ca 100644 --- a/index.js +++ b/index.js @@ -212,10 +212,10 @@ function getModmailChannelInfo(channel) { // (has to do with the api events' consistency), and we only cache IDs, so we return an object that can be // constructed from just the ID; we do this even if we find a matching channel so the returned object's signature is consistent function getModmailChannel(user, allowCreate = true) { - // If the channel id's in the cache, return that + // If the channel id's in the cache, use that if (modMailChannels[user.id]) { return Promise.resolve({ - id: channelId, + id: modMailChannels[user.id], _wasCreated: false, }); }