From 618ab14b4a526680de2853cc40755a80af9b80e6 Mon Sep 17 00:00:00 2001 From: Gary Gregory Date: Sun, 30 Jun 2024 07:49:26 -0400 Subject: [PATCH] Collapse into if-else --- src/main/java/org/apache/commons/logging/LogFactory.java | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/main/java/org/apache/commons/logging/LogFactory.java b/src/main/java/org/apache/commons/logging/LogFactory.java index ce68c2f..c8cfa7a 100644 --- a/src/main/java/org/apache/commons/logging/LogFactory.java +++ b/src/main/java/org/apache/commons/logging/LogFactory.java @@ -898,10 +898,8 @@ public abstract class LogFactory { factory = newFactory(factoryClass, baseClassLoader, contextClassLoader); // TODO: think about whether we need to handle exceptions from newFactory - } else { - if (isDiagnosticsEnabled()) { - logDiagnostic("[LOOKUP] Properties file has no entry specifying LogFactory subclass."); - } + } else if (isDiagnosticsEnabled()) { + logDiagnostic("[LOOKUP] Properties file has no entry specifying LogFactory subclass."); } } else if (isDiagnosticsEnabled()) { logDiagnostic("[LOOKUP] No properties file available to determine" + " LogFactory subclass from..");