Skip to content

Commit a06c6f8

Browse files
authored
Clean up exceptions (#1433)
1 parent 227215b commit a06c6f8

File tree

1 file changed

+2
-8
lines changed

1 file changed

+2
-8
lines changed

maven-release-plugin/src/main/java/org/apache/maven/plugins/release/AbstractReleaseMojo.java

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,6 @@
1919
package org.apache.maven.plugins.release;
2020

2121
import java.io.File;
22-
import java.io.IOException;
2322
import java.nio.file.Path;
2423
import java.util.ArrayList;
2524
import java.util.Arrays;
@@ -146,12 +145,7 @@ protected ReleaseDescriptorBuilder createReleaseDescriptor() {
146145

147146
descriptor.setInteractive(settings.isInteractiveMode());
148147

149-
Path workingDirectory;
150-
try {
151-
workingDirectory = getCommonBasedir(reactorProjects);
152-
} catch (IOException e) {
153-
throw new RuntimeException(e.getMessage());
154-
}
148+
Path workingDirectory = getCommonBasedir(reactorProjects);
155149
descriptor.setWorkingDirectory(workingDirectory.toFile().getAbsolutePath());
156150

157151
Path rootBasedir = basedir.toPath();
@@ -262,7 +256,7 @@ protected void addArgument(String argument) {
262256
}
263257
}
264258

265-
static Path getCommonBasedir(List<MavenProject> reactorProjects) throws IOException {
259+
private static Path getCommonBasedir(List<MavenProject> reactorProjects) {
266260
Path basePath = reactorProjects.get(0).getBasedir().toPath();
267261

268262
for (MavenProject reactorProject : reactorProjects) {

0 commit comments

Comments
 (0)