This commit is contained in:
@@ -96,7 +96,7 @@ internal class Boot
|
|||||||
Console.Title = "ONLINE";
|
Console.Title = "ONLINE";
|
||||||
isReady = true;
|
isReady = true;
|
||||||
|
|
||||||
new Thread(async () =>
|
new Thread(() =>
|
||||||
{
|
{
|
||||||
while (true)
|
while (true)
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -78,8 +78,7 @@ namespace PluginManager
|
|||||||
appConfig = new() { ApplicationVariables = new Dictionary<string, object>(), ProtectedKeyWords = new List<string>() };
|
appConfig = new() { ApplicationVariables = new Dictionary<string, object>(), ProtectedKeyWords = new List<string>() };
|
||||||
}
|
}
|
||||||
|
|
||||||
public static string? GetKey(string value) => appConfig.ApplicationVariables.Keys.FirstOrDefault(x => appConfig.ApplicationVariables[x] == value);
|
public static bool ContainsValue<T>(T value) => appConfig.ApplicationVariables.ContainsValue(value!);
|
||||||
public static bool ContainsValue(string value) => appConfig.ApplicationVariables.ContainsValue(value);
|
|
||||||
public static bool ContainsKey(string key) => appConfig.ApplicationVariables.ContainsKey(key);
|
public static bool ContainsKey(string key) => appConfig.ApplicationVariables.ContainsKey(key);
|
||||||
|
|
||||||
public static Dictionary<string, object> GetAllVariables() => new(appConfig.ApplicationVariables);
|
public static Dictionary<string, object> GetAllVariables() => new(appConfig.ApplicationVariables);
|
||||||
|
|||||||
@@ -188,7 +188,7 @@ public class ConsoleCommandsHandler
|
|||||||
}
|
}
|
||||||
);
|
);
|
||||||
|
|
||||||
AddCommand("add", "add variable to the system variables\nadd [key] [value] [isReadOnly=true/false]", async args =>
|
AddCommand("add", "add variable to the system variables\nadd [key] [value] [isReadOnly=true/false]", args =>
|
||||||
{
|
{
|
||||||
if (args.Length < 4) return;
|
if (args.Length < 4) return;
|
||||||
var key = args[1];
|
var key = args[1];
|
||||||
|
|||||||
Reference in New Issue
Block a user