mirror of
https://github.com/aljazceru/btcpayserver.git
synced 2025-12-18 06:24:24 +01:00
Various plugin fixes (#5577)
* Fix: Plugin updates do not work * Offer install on disabled plugins when different version This will: * Clear any previous pending actions of a plugin if you click uninstall * Show the plugin version that was disabled * Show an update button on disabled plugins instead of install * if a plugin is scheduled to be installed/updated, it will show which version was scheduled to be updated. If a newer version if available than the scheduled one, it will show an option to switch to that * Ensure disabled plugins don't get loaded * View fixes --------- Co-authored-by: d11n <mail@dennisreimann.de>
This commit is contained in:
@@ -108,6 +108,7 @@ namespace BTCPayServer.Plugins
|
||||
public void UninstallPlugin(string plugin)
|
||||
{
|
||||
var dest = _dataDirectories.Value.PluginDir;
|
||||
PluginManager.CancelCommands(dest, plugin);
|
||||
PluginManager.QueueCommands(dest, ("delete", plugin));
|
||||
}
|
||||
|
||||
@@ -155,9 +156,9 @@ namespace BTCPayServer.Plugins
|
||||
PluginManager.CancelCommands(_dataDirectories.Value.PluginDir, plugin);
|
||||
}
|
||||
|
||||
public string[] GetDisabledPlugins()
|
||||
public Dictionary<string, Version> GetDisabledPlugins()
|
||||
{
|
||||
return PluginManager.GetDisabledPlugins(_dataDirectories.Value.PluginDir).ToArray();
|
||||
return PluginManager.GetDisabledPlugins(_dataDirectories.Value.PluginDir);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user