Fixed some warnings
This commit is contained in:
@@ -16,9 +16,9 @@ namespace PluginManager.Core
|
||||
|
||||
private bool isReady = false;
|
||||
|
||||
public DiscordSocketClient? client;
|
||||
private CommandHandler? commandServiceHandler;
|
||||
private CommandService? service;
|
||||
public DiscordSocketClient client;
|
||||
private CommandHandler commandServiceHandler;
|
||||
private CommandService service;
|
||||
|
||||
public Boot(string botToken, string botPrefix)
|
||||
{
|
||||
|
||||
@@ -11,6 +11,7 @@ using PluginManager.Loaders;
|
||||
using System.Threading.Tasks;
|
||||
using System.Linq;
|
||||
using Discord;
|
||||
using System;
|
||||
|
||||
namespace PluginManager.Core
|
||||
{
|
||||
@@ -21,7 +22,7 @@ namespace PluginManager.Core
|
||||
private readonly string botPrefix;
|
||||
|
||||
internal static bool awaitRestartOnSetCommand = false;
|
||||
internal static SocketUser? RestartOnSetCommandCaster = null;
|
||||
internal static SocketUser RestartOnSetCommandCaster = null;
|
||||
|
||||
public CommandHandler(DiscordSocketClient client, CommandService commandService, string botPrefix)
|
||||
{
|
||||
@@ -72,6 +73,7 @@ namespace PluginManager.Core
|
||||
}
|
||||
var fileName = Assembly.GetExecutingAssembly().Location;
|
||||
System.Diagnostics.Process.Start(fileName);
|
||||
Environment.Exit(0);
|
||||
}
|
||||
}
|
||||
return;
|
||||
@@ -85,7 +87,7 @@ namespace PluginManager.Core
|
||||
services: null
|
||||
);
|
||||
|
||||
DBCommand? plugin = PluginLoader.Plugins!.Where(p => p.Command == (message.Content.Split(' ')[0]).Substring(botPrefix.Length)).FirstOrDefault();
|
||||
DBCommand plugin = PluginLoader.Plugins!.Where(p => p.Command == (message.Content.Split(' ')[0]).Substring(botPrefix.Length)).FirstOrDefault();
|
||||
|
||||
|
||||
if (plugin != null)
|
||||
|
||||
@@ -24,6 +24,7 @@ namespace PluginManager.Online
|
||||
return s;
|
||||
}
|
||||
|
||||
[System.Diagnostics.CodeAnalysis.SuppressMessage("Interoperability", "CA1416:Validate platform compatibility", Justification = "<Pending>")]
|
||||
public static async Task DownloadFileAsync(string url, string location, int downloadNumber, int totalToDownload)
|
||||
{
|
||||
WebClient client = new WebClient();
|
||||
|
||||
Reference in New Issue
Block a user