mirror of
https://github.com/Stone-Red-Code/DesktopMagic.git
synced 2026-09-04 00:46:12 +02:00
Add try catch when stopping plugin
This commit is contained in:
@@ -428,7 +428,15 @@ public partial class PluginWindow : Window
|
||||
{
|
||||
App.Logger.LogInfo($"\"{PluginMetadata.Name}\" - Stopping plugin", source: "Plugin");
|
||||
IsRunning = false;
|
||||
pluginClassInstance?.Stop();
|
||||
|
||||
try
|
||||
{
|
||||
pluginClassInstance?.Stop();
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
App.Logger.LogError($"\"{PluginMetadata.Name}\" - {ex}", source: "Plugin");
|
||||
}
|
||||
}
|
||||
|
||||
#region Window Events
|
||||
|
||||
Reference in New Issue
Block a user