boolean (@Nullable JComponent parentComponent, @NotNull IdeaPluginDescriptorImpl pluginDescriptor, boolean isUpdate) { if (pluginDescriptor.isBundled()) { throw new IllegalArgumentException("Plugin is bundled: " + pluginDescriptor.getPluginId()); } boolean uninstalledWithoutRestart = !pluginDescriptor.isEnabled() || unloadDynamicPlugin(parentComponent, pluginDescriptor, isUpdate); if (uninstalledWithoutRestart) { try { FileUtil.delete(pluginDescriptor.getPluginPath()); } catch (IOException e) { LOG.info("Failed to delete jar of dynamic plugin", e); uninstalledWithoutRestart = false; } } if (!uninstalledWithoutRestart) { try { uninstallAfterRestart(pluginDescriptor); } catch (IOException e) { LOG.error(e); } } return uninstalledWithoutRestart; }