Skip to content

Commit

Permalink
Remove extra check for SLF4J nop logger, fixes: #77
Browse files Browse the repository at this point in the history
  • Loading branch information
cruftex committed Dec 29, 2017
1 parent c7929cc commit b87b6b8
Showing 1 changed file with 8 additions and 10 deletions.
18 changes: 8 additions & 10 deletions cache2k-core/src/main/java/org/cache2k/core/util/Log.java
Original file line number Diff line number Diff line change
Expand Up @@ -81,16 +81,14 @@ private static void initializeLogFactory() {
}
try {
final org.slf4j.ILoggerFactory lf = org.slf4j.LoggerFactory.getILoggerFactory();
if (!(lf instanceof NOPLoggerFactory)) {
logFactory = new LogFactory() {
@Override
public Log getLog(String s) {
return new Slf4jLogger(lf.getLogger(s));
}
};
log("New instance, using SLF4J logging");
return;
}
logFactory = new LogFactory() {
@Override
public Log getLog(String s) {
return new Slf4jLogger(lf.getLogger(s));
}
};
log("New instance, using SLF4J logging");
return;
} catch (NoClassDefFoundError ignore) {
}
try {
Expand Down

0 comments on commit b87b6b8

Please sign in to comment.