- Started cleanup of command handler

- Removed IUnloadableService
- Started removing INService (removed it from services which implement behavior interfaces) - wip
- Added scrutor for better service registration - wip
This commit is contained in:
Kwoth
2021-06-28 23:20:02 +02:00
parent 1e90d7f7bb
commit 3c82c1f919
30 changed files with 217 additions and 360 deletions

View File

@@ -17,7 +17,7 @@ using Serilog;
namespace NadekoBot.Modules.Utility.Services
{
public class StreamRoleService : INService, IUnloadableService
public class StreamRoleService : INService
{
private readonly DbService _db;
private readonly DiscordSocketClient _client;
@@ -48,12 +48,6 @@ namespace NadekoBot.Modules.Utility.Services
});
}
public Task Unload()
{
_client.GuildMemberUpdated -= Client_GuildMemberUpdated;
return Task.CompletedTask;
}
private Task Client_GuildMemberUpdated(SocketGuildUser before, SocketGuildUser after)
{
var _ = Task.Run(async () =>