Skip to content

Commit ee6de1f

Browse files
committed
optimize
1 parent 599a87e commit ee6de1f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

opengrok-indexer/src/main/java/org/opengrok/indexer/util/Statistics.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,8 +44,8 @@ public Statistics() {
4444
}
4545

4646
private void logIt(Logger logger, Level logLevel, String msg, Duration duration) {
47-
String timeStr = StringUtils.getReadableTime(duration.toMillis());
4847
if (logger.isLoggable(logLevel)) {
48+
String timeStr = StringUtils.getReadableTime(duration.toMillis());
4949
logger.log(logLevel, String.format("%s (took %s)", msg, timeStr));
5050
}
5151
}

0 commit comments

Comments
 (0)