Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
[FIXED JENKINS-20031] Useful error message when UC not found
(cherry picked from commit a4b63d2)
  • Loading branch information
daniel-beck authored and olivergondza committed Jul 2, 2014
1 parent c3ddea2 commit 2f19b5c
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 @@ -732,7 +732,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 2f19b5c

Please sign in to comment.