]> source.dussan.org Git - archiva.git/commitdiff
MRM-710: Use commons-lang instead of Plexus Utils
authorJoakim Erdfelt <joakime@apache.org>
Fri, 14 Mar 2008 05:39:17 +0000 (05:39 +0000)
committerJoakim Erdfelt <joakime@apache.org>
Fri, 14 Mar 2008 05:39:17 +0000 (05:39 +0000)
Replacing plexus utils StringUtils with FilenameUtils.

git-svn-id: https://svn.apache.org/repos/asf/maven/archiva/trunk@636997 13f79535-47bb-0310-9956-ffa450edef68

archiva-base/archiva-repository-layer/src/main/java/org/apache/maven/archiva/repository/scanner/functors/ConsumerWantsFilePredicate.java

index 29e3ef41957d07f9f4d416dda51f45d7a4c37aa2..97e97b4074ea05bb06304947f7b6e992e2fb83a9 100644 (file)
@@ -20,10 +20,10 @@ package org.apache.maven.archiva.repository.scanner.functors;
  */
 
 import org.apache.commons.collections.Predicate;
+import org.apache.commons.io.FilenameUtils;
 import org.apache.maven.archiva.common.utils.BaseFile;
 import org.apache.maven.archiva.consumers.RepositoryContentConsumer;
 import org.codehaus.plexus.util.SelectorUtils;
-import org.codehaus.plexus.util.StringUtils;
 
 import java.util.List;
 
@@ -51,7 +51,7 @@ public class ConsumerWantsFilePredicate
         if ( object instanceof RepositoryContentConsumer )
         {
             RepositoryContentConsumer consumer = (RepositoryContentConsumer) object;
-            if ( wantsFile( consumer, StringUtils.replace( basefile.getRelativePath(), "\\", "/" ) ) )
+            if ( wantsFile( consumer, FilenameUtils.separatorsToUnix( basefile.getRelativePath() ) ) )
             {
                 satisfies = true;