Skip to content

Commit 3cc801f

Browse files
IO-886 Replaced incorrect regular expression replaceAll with plain replace (#828)
1 parent 3163c62 commit 3cc801f

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/main/java/org/apache/commons/io/file/PathUtils.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -139,7 +139,7 @@ private static boolean equalsIgnoreFileSystem(final Path path1, final Path path2
139139

140140
static String extractKey(final String separator, final String string) {
141141
// Replace the file separator in a path string with a string that is not legal in a path on Windows, Linux, and macOS.
142-
return string.replaceAll("\\" + separator, ">");
142+
return string.replace(separator, ">");
143143
}
144144

145145
final boolean equals;

0 commit comments

Comments
 (0)