mirror of
https://github.com/scm-manager/scm-manager.git
synced 2025-11-14 17:26:22 +01:00
Prohibit uninstallation of core plugins
This commit is contained in:
@@ -188,6 +188,7 @@ public class DefaultPluginManager implements PluginManager {
|
||||
PluginPermissions.manage().check();
|
||||
InstalledPlugin installed = getInstalled(name)
|
||||
.orElseThrow(() -> NotFoundException.notFound(entity(InstalledPlugin.class, name)));
|
||||
doThrow().violation("plugin is a core plugin and cannot be uninstalled").when(installed.isCore());
|
||||
|
||||
dependencyTracker.removeInstalled(installed.getDescriptor());
|
||||
|
||||
|
||||
Reference in New Issue
Block a user