Fixed duplicate actions

This commit is contained in:
2024-06-14 17:09:02 +03:00
parent e5e156f371
commit 1881102fb7
4 changed files with 23 additions and 5 deletions

View File

@@ -38,6 +38,18 @@ public class PluginLoader
public async Task LoadPlugins()
{
if (_Client == null)
{
Application.CurrentApplication.Logger.Log("Discord client is null", this, LogType.ERROR);
return;
}
Commands.Clear();
Events.Clear();
SlashCommands.Clear();
Actions.Clear();
Application.CurrentApplication.Logger.Log("Loading plugins...", this);
var loader = new Loader();