From 9a548b3b3e5d69bc776383860a0611babd654d7b Mon Sep 17 00:00:00 2001 From: "[IPSA] Chris de Claverie" Date: Mon, 28 Sep 2020 00:15:03 +0200 Subject: Plugin reload feature (#4942) + Add `reload ` * Fixes #365 Co-authored-by: Alexander Harkness Co-authored-by: pwnOrbitals Co-authored-by: Tiger Wang --- src/Server.cpp | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'src/Server.cpp') diff --git a/src/Server.cpp b/src/Server.cpp index 67629ef2c..2730d3511 100644 --- a/src/Server.cpp +++ b/src/Server.cpp @@ -463,7 +463,15 @@ void cServer::ExecuteConsoleCommand(const AString & a_Cmd, cCommandOutputCallbac } else if (split[0] == "reload") { - cPluginManager::Get()->ReloadPlugins(); + if (split.size() > 1) + { + cPluginManager::Get()->ReloadPlugin(split[1]); + a_Output.Out("Plugin reload scheduled"); + } + else + { + cPluginManager::Get()->ReloadPlugins(); + } a_Output.Finished(); return; } -- cgit v1.2.3