Skip to content

Commit

Permalink
[FIXED JENKINS-20031] Useful error message when UC not found
Browse files Browse the repository at this point in the history
  • Loading branch information
daniel-beck committed May 19, 2014
1 parent 016f304 commit a4b63d2
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion core/src/main/java/hudson/PluginManager.java
Expand Up @@ -721,7 +721,9 @@ public void doInstall(StaplerRequest req, StaplerResponse rsp) throws IOExceptio
String pluginName = n.substring(0, index);
String siteName = n.substring(index + 1);
UpdateSite updateSite = Jenkins.getInstance().getUpdateCenter().getById(siteName);
if (siteName != null) {
if (updateSite == null) {
throw new Failure("No such update center: " + siteName);
} else {
UpdateSite.Plugin plugin = updateSite.getPlugin(pluginName);
if (plugin != null) {
if (p != null) {
Expand Down

0 comments on commit a4b63d2

Please sign in to comment.