Merge pull request #167 from acw0/master
Add current shard ID in status message
This commit is contained in:
commit
c551533313
@ -120,7 +120,8 @@ namespace PluralKit.Bot
|
|||||||
var totalGuilds = _client.ShardClients.Values.Sum(c => c.Guilds.Count);
|
var totalGuilds = _client.ShardClients.Values.Sum(c => c.Guilds.Count);
|
||||||
try // DiscordClient may throw an exception if the socket is closed (e.g just after OP 7 received)
|
try // DiscordClient may throw an exception if the socket is closed (e.g just after OP 7 received)
|
||||||
{
|
{
|
||||||
await _client.UpdateStatusAsync(new DiscordActivity($"pk;help | in {totalGuilds} servers"));
|
foreach (var c in _client.ShardClients.Values)
|
||||||
|
await c.UpdateStatusAsync(new DiscordActivity($"pk;help | in {totalGuilds} servers | Shard {c.ShardId}"));
|
||||||
}
|
}
|
||||||
catch (WebSocketException) { }
|
catch (WebSocketException) { }
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user