aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIRONM00N <64110067+IRONM00N@users.noreply.github.com>2021-12-29 16:20:28 -0500
committerIRONM00N <64110067+IRONM00N@users.noreply.github.com>2021-12-29 16:20:28 -0500
commit2d7b790b31a2febcea8878a2b0b4b28ec0fbee40 (patch)
tree86f60f915ac16511b34c2b163bf065eb4c99f5a4
parentdcdfc1fda7cfedf7c0f69ba51857fd7ebc71a2dd (diff)
downloadtanzanite-2d7b790b31a2febcea8878a2b0b4b28ec0fbee40.tar.gz
tanzanite-2d7b790b31a2febcea8878a2b0b4b28ec0fbee40.tar.bz2
tanzanite-2d7b790b31a2febcea8878a2b0b4b28ec0fbee40.zip
make autopublisher log to guild error channel
-rw-r--r--src/listeners/message/autoPublisher.ts7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/listeners/message/autoPublisher.ts b/src/listeners/message/autoPublisher.ts
index be8fc3e..af75ea3 100644
--- a/src/listeners/message/autoPublisher.ts
+++ b/src/listeners/message/autoPublisher.ts
@@ -19,9 +19,10 @@ export default class autoPublisherListener extends BushListener {
.then(
() => void client.logger.log('autoPublisher', `Published message <<${message.id}>> in <<${message.guild!.name}>>.`)
)
- .catch(
- () => void client.console.warn('autoPublisher', `Failed to publish <<${message.id}>> in <<${message.guild!.name}>>.`)
- );
+ .catch(() => {
+ void client.console.log('autoPublisher', `Failed to publish <<${message.id}>> in <<${message.guild!.name}>>.`);
+ void message.guild?.error('autoPublisher', `Unable to publish message id ${message.id} in <#${message.channel.id}>.`);
+ });
}
}
}