Skip to content

Commit

Permalink
Fix for JENKINS-13242
Browse files Browse the repository at this point in the history
  • Loading branch information
hajush committed Mar 30, 2012
1 parent de91093 commit b6563fa
Showing 1 changed file with 3 additions and 3 deletions.
Expand Up @@ -301,6 +301,8 @@ public boolean configure(StaplerRequest req, JSONObject formData)
throws FormException {
// Most of this stuff is the same as the built-in email publisher

overrideGlobalSettings = req.getParameter("ext_mailer_override_global_settings") != null;

// Configure the smtp server
smtpHost = nullify(req.getParameter("ext_mailer_smtp_server"));
adminAddress = req.getParameter("ext_mailer_admin_address");
Expand All @@ -311,7 +313,7 @@ public boolean configure(StaplerRequest req, JSONObject formData)
if (url != null && !url.endsWith("/")) {
url += '/';
}
if (url == null) {
if (!overrideGlobalSettings || url == null) {
url = Hudson.getInstance().getRootUrl();
}
hudsonUrl = url;
Expand Down Expand Up @@ -346,8 +348,6 @@ public boolean configure(StaplerRequest req, JSONObject formData)
(Long.parseLong(req.getParameter("ext_mailer_max_attachment_size")) * 1024 * 1024) : -1;
recipientList = nullify(req.getParameter("ext_mailer_default_recipients")) != null ?
req.getParameter("ext_mailer_default_recipients") : "";

overrideGlobalSettings = req.getParameter("ext_mailer_override_global_settings") != null;

precedenceBulk = req.getParameter("extmailer.addPrecedenceBulk") != null;

Expand Down

0 comments on commit b6563fa

Please sign in to comment.