Adds bot exit command for bot creator

This commit is contained in:
Deukhoofd 2019-08-17 15:32:04 +02:00
parent e6293716f9
commit 597712b282
Signed by: Deukhoofd
GPG Key ID: ADF2E9256009EDCE
1 changed files with 8 additions and 1 deletions

View File

@ -1,4 +1,5 @@
using System.Threading.Tasks;
using System;
using System.Threading.Tasks;
using DeukBot4.MessageHandlers.CommandHandler.RequestStructure;
using DeukBot4.MessageHandlers.Permissions;
using Discord;
@ -58,5 +59,11 @@ namespace DeukBot4.MessageHandlers.CommandHandler
await channel.SendMessageAsync(request.Parameters[1].AsString());
}
[Command("exit", PermissionLevel.BotCreator)]
public async Task ExitBot(CommandRequest request)
{
Environment.Exit(0);
}
}
}