[FIXED JENKINS-22080] Braindead logic in author of original fix... corrected by same author

This commit is contained in:
Stephen Connolly committed 2014-03-07 15:29:21 +00:00
1 parent f9b0f348d0
commit 483181c0a1
1 file changed
+6 -3
+6 -3
View File
@@ -695,10 +695,13 @@ public abstract class PluginManager extends AbstractModelObject implements OnMas
String siteName = n.substring(index + 1);
UpdateSite updateSite = Jenkins.getInstance().getUpdateCenter().getById(siteName);
if (siteName != null) {
if (p != null) {
throw new Failure("Ambiguous plugin: " + n);
UpdateSite.Plugin plugin = updateSite.getPlugin(pluginName);
if (plugin != null) {
if (p != null) {
throw new Failure("Ambiguous plugin: " + n);
}
p = plugin;
}
p = updateSite.getPlugin(pluginName);
}
index = n.indexOf('.', index + 1);
}