mirror of
https://github.com/tribufu/ServerManagers
synced 2026-05-06 15:17:34 +00:00
21 lines
462 B
C#
21 lines
462 B
C#
using Discord.WebSocket;
|
|
using System.Threading.Tasks;
|
|
|
|
namespace ServerManagerTool.Discord.Services
|
|
{
|
|
public class ShutdownService
|
|
{
|
|
private readonly DiscordSocketClient _discord;
|
|
|
|
public ShutdownService(DiscordSocketClient discord)
|
|
{
|
|
_discord = discord;
|
|
}
|
|
|
|
public async Task StopAsync()
|
|
{
|
|
await _discord.StopAsync();
|
|
await _discord.LogoutAsync();
|
|
}
|
|
}
|
|
}
|