Simplify.
Remove TODO inline comments I previously wrote.
MODIFY
src/main/java/org/apache/commons/io/FileUtils.java
src/main/java/org/apache/commons/io/FileUtils.java
@@ -1427,11 +1427,7 @@ public static void forceMkdir(final File directory) throws IOException {
*/
public static void forceMkdirParent(final File file) throws IOException {
Objects.requireNonNull(file, "file");
- final File parent = getParentFile(file);
- if (parent == null) {
- return;
- }
- forceMkdir(parent);
+ forceMkdir(getParentFile(file));
}
/**
@@ -1660,7 +1656,6 @@ public static boolean isFileNewer(final File file, final ChronoZonedDateTime<?>
try {
return PathUtils.isNewer(file.toPath(), chronoZonedDateTime);
} catch (final IOException e) {
- // TODO Update method signature
throw new UncheckedIOException(e);
}
}
@@ -1694,7 +1689,6 @@ public static boolean isFileNewer(final File file, final File reference) {
try {
return PathUtils.isNewer(file.toPath(), reference.toPath());
} catch (final IOException e) {
- // TODO Update method signature
throw new UncheckedIOException(e);
}
}
@@ -1730,7 +1724,6 @@ public static boolean isFileNewer(final File file, final Instant instant) {
try {
return PathUtils.isNewer(file.toPath(), instant);
} catch (final IOException e) {
- // TODO Update method signature
throw new UncheckedIOException(e);
}
}
@@ -1749,7 +1742,6 @@ public static boolean isFileNewer(final File file, final long timeMillis) {
try {
return PathUtils.isNewer(file.toPath(), timeMillis);
} catch (final IOException e) {
- // TODO Update method signature
throw new UncheckedIOException(e);
}
}
@@ -1887,7 +1879,6 @@ public static boolean isFileOlder(final File file, final File reference) {
try {
return PathUtils.isOlder(file.toPath(), reference.toPath());
} catch (final IOException e) {
- // TODO Update method signature
throw new UncheckedIOException(e);
}
}
@@ -1922,7 +1913,6 @@ public static boolean isFileOlder(final File file, final Instant instant) {
try {
return PathUtils.isOlder(file.toPath(), instant);
} catch (final IOException e) {
- // TODO Update method signature
throw new UncheckedIOException(e);
}
}
@@ -1941,7 +1931,6 @@ public static boolean isFileOlder(final File file, final long timeMillis) {
try {
return PathUtils.isOlder(file.toPath(), timeMillis);
} catch (final IOException e) {
- // TODO Update method signature
throw new UncheckedIOException(e);
}
}
@@ -2967,7 +2956,6 @@ public static long sizeOf(final File file) {
try {
return PathUtils.sizeOf(file.toPath());
} catch (final IOException e) {
- // TODO Update method signature
throw new UncheckedIOException(e);
}
}
@@ -2996,7 +2984,6 @@ public static BigInteger sizeOfAsBigInteger(final File file) {
try {
return PathUtils.sizeOfAsBigInteger(file.toPath());
} catch (final IOException e) {
- // TODO Update method signature
throw new UncheckedIOException(e);
}
}
@@ -3020,7 +3007,6 @@ public static long sizeOfDirectory(final File directory) {
try {
return PathUtils.sizeOfDirectory(directory.toPath());
} catch (final IOException e) {
- // TODO Update method signature
throw new UncheckedIOException(e);
}
}
@@ -3039,7 +3025,6 @@ public static BigInteger sizeOfDirectoryAsBigInteger(final File directory) {
try {
return PathUtils.sizeOfDirectoryAsBigInteger(directory.toPath());
} catch (final IOException e) {
- // TODO Update method signature
throw new UncheckedIOException(e);
}

Simplify.

Remove TODO inline comments I previously wrote.