mirror of
https://github.com/PluralKit/PluralKit.git
synced 2026-02-04 13:06:50 +00:00
Skip messages before current user ID is established
This commit is contained in:
parent
20789411f6
commit
0eb2e8be6f
1 changed files with 1 additions and 1 deletions
|
|
@ -260,7 +260,7 @@ namespace PluralKit.Bot
|
|||
public async Task HandleMessage(SocketMessage arg)
|
||||
{
|
||||
var shard = _client.GetShardFor((arg.Channel as IGuildChannel)?.Guild);
|
||||
if (shard.ConnectionState != ConnectionState.Connected)
|
||||
if (shard.ConnectionState != ConnectionState.Connected || _client.CurrentUser == null)
|
||||
return; // Discard messages while the bot "catches up" to avoid unnecessary CPU pressure causing timeouts
|
||||
|
||||
RegisterMessageMetrics(arg);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue