This is an automated email from the ASF dual-hosted git repository.

juanpablo pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/jspwiki.git


The following commit(s) were added to refs/heads/master by this push:
     new 5eeb34041 minor change to use the os utils class commons-lang3 that 
was already in the classpath
5eeb34041 is described below

commit 5eeb3404120949d21cfc5ac4704eede6b7a37a30
Author: Alex <[email protected]>
AuthorDate: Sun Sep 15 11:28:41 2024 -0400

    minor change to use the os utils class commons-lang3 that was already in 
the classpath
---
 .../main/java/org/apache/wiki/providers/AbstractFileProvider.java   | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)

diff --git 
a/jspwiki-main/src/main/java/org/apache/wiki/providers/AbstractFileProvider.java
 
b/jspwiki-main/src/main/java/org/apache/wiki/providers/AbstractFileProvider.java
index 35b5b920f..29e4ac9d8 100644
--- 
a/jspwiki-main/src/main/java/org/apache/wiki/providers/AbstractFileProvider.java
+++ 
b/jspwiki-main/src/main/java/org/apache/wiki/providers/AbstractFileProvider.java
@@ -52,6 +52,7 @@ import java.util.List;
 import java.util.Map;
 import java.util.Properties;
 import java.util.TreeSet;
+import org.apache.commons.lang3.SystemUtils;
 
 
 /**
@@ -135,10 +136,7 @@ public abstract class AbstractFileProvider implements 
PageProvider {
 
         m_engine = engine;
         m_encoding = properties.getProperty( Engine.PROP_ENCODING, 
DEFAULT_ENCODING );
-        final String os = System.getProperty( "os.name" ).toLowerCase();
-        if( os.startsWith( "windows" ) || os.equals( "nt" ) ) {
-            m_windowsHackNeeded = true;
-        }
+        m_windowsHackNeeded = SystemUtils.IS_OS_WINDOWS;
 
         MAX_PROPLIMIT = TextUtil.getIntegerProperty( properties, 
PROP_CUSTOMPROP_MAXLIMIT, DEFAULT_MAX_PROPLIMIT );
         MAX_PROPKEYLENGTH = TextUtil.getIntegerProperty( properties, 
PROP_CUSTOMPROP_MAXKEYLENGTH, DEFAULT_MAX_PROPKEYLENGTH );

Reply via email to