diff --git a/core/src/main/java/hudson/tasks/MailAddressResolver.java b/core/src/main/java/hudson/tasks/MailAddressResolver.java index 8ccbb9a82e39aa497bd411ed361350b1d585d47d..d914dc20570f76ff3d784d614a8a587843e09c05 100644 --- a/core/src/main/java/hudson/tasks/MailAddressResolver.java +++ b/core/src/main/java/hudson/tasks/MailAddressResolver.java @@ -33,6 +33,7 @@ import hudson.model.UserProperty; import hudson.scm.SCM; import java.util.List; +import java.util.logging.Level; import java.util.logging.Logger; import java.util.regex.Matcher; import java.util.regex.Pattern; @@ -41,7 +42,7 @@ import java.util.regex.Pattern; * Infers e-mail addresses for the user when none is specified. * *

- * This is an extension point of Hudson. Plugins tha contribute new implementation + * This is an extension point of Jenkins. Plugins that contribute a new implementation * of this class should put {@link Extension} on your implementation class, like this: * *

@@ -53,7 +54,7 @@ import java.util.regex.Pattern;
  *
  * 

Techniques

*

- * User identity in Hudson is global, and not specific to a particular job. As a result, mail address resolution + * User identity in Jenkins is global, and not specific to a particular job. As a result, mail address resolution * only receives {@link User}, which by itself doesn't really have that much information in it. * *

@@ -91,12 +92,16 @@ public abstract class MailAddressResolver implements ExtensionPoint { public abstract String findMailAddressFor(User u); public static String resolve(User u) { - LOGGER.fine("Resolving e-mail address for \""+u+"\" ID="+u.getId()); + if (LOGGER.isLoggable(Level.FINE)) { + LOGGER.fine("Resolving e-mail address for \""+u+"\" ID="+u.getId()); + } for (MailAddressResolver r : all()) { String email = r.findMailAddressFor(u); if(email!=null) { - LOGGER.fine(r+" resolved "+u.getId()+" to "+email); + if (LOGGER.isLoggable(Level.FINE)) { + LOGGER.fine(r+" resolved "+u.getId()+" to "+email); + } return email; } }