Skip to content

Commit

Permalink
extract #loggerNameMismatch to a constant
Browse files Browse the repository at this point in the history
  • Loading branch information
ceki committed Dec 13, 2014
1 parent 175c8e4 commit 4ad29d1
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion slf4j-api/src/main/java/org/slf4j/LoggerFactory.java
Expand Up @@ -70,6 +70,7 @@ public final class LoggerFactory {
static final String NULL_LF_URL = CODES_PREFIX + "#null_LF";
static final String VERSION_MISMATCH = CODES_PREFIX + "#version_mismatch";
static final String SUBSTITUTE_LOGGER_URL = CODES_PREFIX + "#substituteLogger";
static final String LOGGER_NAME_MISMATCH_URL = CODES_PREFIX + "#loggerNameMismatch";

static final String UNSUCCESSFUL_INIT_URL = CODES_PREFIX + "#unsuccessfulInit";
static final String UNSUCCESSFUL_INIT_MSG = "org.slf4j.LoggerFactory could not be successfully initialized. See also "
Expand Down Expand Up @@ -302,7 +303,7 @@ public static Logger getLogger(@Nonnull Class<?> clazz) {
if (nonMatchingClasses(clazz, autoComputedCallingClass)) {
Util.report(String.format("Detected logger name mismatch. Given name: \"%s\"; computed name: \"%s\". ",
logger.getName(), autoComputedCallingClass.getName()));
Util.report("See http://www.slf4j.org/codes.html#loggerNameMismatch for an explanation");
Util.report("See " + LOGGER_NAME_MISMATCH_URL + " for an explanation");
}
}
return logger;
Expand Down

0 comments on commit 4ad29d1

Please sign in to comment.